Commit 2ef15dd0 by Sebastián Katzer

Merge pull request #534 from AttackTheDarkness/platforms_fix

Updated the location for Cordova's platforms module
parents 31fee38d c9ddb0cf
......@@ -39,10 +39,16 @@ module.exports = function (context) {
var cordova_util = context.requireCordovaModule('cordova-lib/src/cordova/util'),
ConfigParser = context.requireCordovaModule('cordova-lib/src/configparser/ConfigParser'),
platforms = context.requireCordovaModule('cordova-lib/src/cordova/platforms'),
projectRoot = cordova_util.isCordova(),
xml = cordova_util.projectConfig(projectRoot),
cfg = new ConfigParser(xml);
// Cordova moved the platforms stuff; try both locations so we'll work for new and old file layouts.
var platforms;
try {
platforms = context.requireCordovaModule('cordova-lib/src/cordova/platforms');
} catch(e) {
platforms = context.requireCordovaModule('cordova-lib/src/platforms/platforms');
}
/**
* The absolute path for the file.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment