Fixed phonegap.isLoaded() call