mirror of
https://github.com/apache/cordova-android.git
synced 2025-01-19 07:02:51 +08:00
CB-11095 Fix plugin add/removal when running on Node v.010
This commit is contained in:
parent
9b8558dbde
commit
9af7f506f0
2
bin/templates/cordova/lib/pluginHandlers.js
vendored
2
bin/templates/cordova/lib/pluginHandlers.js
vendored
@ -152,7 +152,7 @@ var handlers = {
|
||||
install: function (obj, plugin, project, options) {
|
||||
// Copy the plugin's files into the www directory.
|
||||
var moduleSource = path.resolve(plugin.dir, obj.src);
|
||||
var moduleName = plugin.id + '.' + (obj.name || path.parse(obj.src).name);
|
||||
var moduleName = plugin.id + '.' + (obj.name || path.basename(obj.src, path.extname (obj.src)));
|
||||
|
||||
// Read in the file, prepend the cordova.define, and write it back out.
|
||||
var scriptContent = fs.readFileSync(moduleSource, 'utf-8').replace(/^\ufeff/, ''); // Window BOM
|
||||
|
@ -164,7 +164,7 @@ describe('android project handler', function() {
|
||||
});
|
||||
|
||||
describe('of <js-module> elements', function() {
|
||||
var jsModule = {src: 'www/dummyPlugin.js'};
|
||||
var jsModule = {src: 'www/dummyplugin.js'};
|
||||
var wwwDest, platformWwwDest;
|
||||
|
||||
beforeEach(function () {
|
||||
|
Loading…
Reference in New Issue
Block a user