Update for Phonegap