Skip to content
This repository has been archived by the owner on Dec 6, 2023. It is now read-only.

Commit

Permalink
Clean up shadowed variables
Browse files Browse the repository at this point in the history
  • Loading branch information
Jon Duckworth committed Nov 21, 2017
1 parent 55dcbe9 commit c28f3da
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions lib/setup/install.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,8 @@ var avn = function() {
* complete and indicates if any action took place.
*/
var plugins = function() {
return installedPlugins().then(function(plugins) {
return Promise.all(plugins.map(function(plugin) {
return installedPlugins().then(function(_plugins) {
return Promise.all(_plugins.map(function(plugin) {
var src = plugin.path + '/';
var dst = path.join(process.env.HOME,
path.join('.avn/plugins', plugin.moduleName));
Expand Down
10 changes: 5 additions & 5 deletions lib/setup/plugins.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ var path = require('path');
var modules = function() {
return Promise.resolve()
.then(function() { return npm.loadAsync(); })
.then(function(npm) {
npm.config.set('spin', false);
npm.config.set('global', true);
npm.config.set('depth', 0);
return Promise.promisify(npm.commands.list)([], true);
.then(function(_npm) {
_npm.config.set('spin', false);
_npm.config.set('global', true);
_npm.config.set('depth', 0);
return Promise.promisify(_npm.commands.list)([], true);
})
.then(function(data) { return data; });
};
Expand Down
4 changes: 2 additions & 2 deletions lib/setup/profile.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ var isNoEntry = require('../util/codes').isNoEntry;
* @return {String} The string to be included in the init script.
*/
var script = function() {
var script = '$HOME/.avn/bin/avn.sh';
var _script = '$HOME/.avn/bin/avn.sh';
return util.format('[[ -s "%s" ]] && source "%s" # load avn\n',
script, script);
_script, _script);
};

/**
Expand Down

0 comments on commit c28f3da

Please sign in to comment.