ngCordova sqlite error

I’m following this link: http://ngcordova.com/docs/plugins/sqlite/

But I get the following error:
Error: undefined is not an object (evaluating ‘n.sqlitePlugin.openDatabase’

What am I doing wrong?