Updating Core

More to make it work with phonegap.