switch to upload with cordova plugin