Both methods updated for and tested on Cordova 1.6.1
Merge pull request #2 from mdreeling/master

Both methods updated for and tested on Cordova 1.6.1