fix for phonegap