apla / me.apla.cordova.app-preferences

App preferences plugin for cordova
Apache License 2.0
201 stars 209 forks source link

Update apppreferences.js #24

Closed kmd-jamesgauld closed 9 years ago

kmd-jamesgauld commented 9 years ago

When building I received an "Unexpected token &&" error which, as far as I can tell, is a result of the following lines:

if (successCallback !== undefined
        && typeof successCallback !== function && typeof errorCallback !== function
        && dict === undefined && key === undefined
        && promiseLib
    )

The proposed change encapsulates the 'function' typeof checks in quotes to fix the fault.