Github user vladimir-kotikov commented on a diff in the pull request: https://github.com/apache/cordova-lib/pull/396#discussion_r54222593 --- Diff: cordova-lib/src/plugman/install.js --- @@ -79,21 +79,36 @@ module.exports = function installPlugin(platform, project_dir, id, plugins_dir, } var current_stack = new action_stack(); - // Split @Version from the plugin id if it exists. var splitVersion = id.split('@'); //Check if a mapping exists for the plugin id //if it does, convert id to new name id - var newId = pluginMapper[splitVersion[0]]; + var newId = pluginMapper.oldToNew[splitVersion[0]]; if(newId) { - events.emit('warn', 'Notice: ' + id + ' has been automatically converted to ' + newId + ' and fetched from npm. This is due to our old plugins registry shutting down.'); if(splitVersion[1]) { id = newId +'@'+splitVersion[1]; } else { id = newId; } - } - return possiblyFetch(id, plugins_dir, options) + } + var P; --- End diff -- I'd move the chunk below to `possiblyFetch` function. This way you could just `return Q(plugin_dir)` instead of using intermediate variable. Also `possiblyFetch` already contains logic to check existence of plugin directory.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org For additional commands, e-mail: dev-h...@cordova.apache.org