make execute take the vcs as well

This commit is contained in:
Siddharth Agarwal 2013-07-31 01:24:03 -07:00
parent d04817f7d1
commit 7f43138665
3 changed files with 9 additions and 6 deletions

View file

@ -8859,8 +8859,9 @@ GitEngine.prototype.dispatch = function(command, deferred) {
}); });
try { try {
var vcs = command.get('vcs');
var methodName = command.get('method').replace(/-/g, ''); var methodName = command.get('method').replace(/-/g, '');
GitCommands.commands.execute(methodName, this, this.command); GitCommands.commands.execute(vcs, methodName, this, this.command);
} catch (err) { } catch (err) {
this.filterError(err); this.filterError(err);
// short circuit animation by just setting error and returning // short circuit animation by just setting error and returning
@ -9877,7 +9878,7 @@ var CommandResult = Errors.CommandResult;
var commandConfig; var commandConfig;
var commands = { var commands = {
execute: function(name, engine, commandObj) { execute: function(vcs, name, engine, commandObj) {
if (!commandConfig[name]) { if (!commandConfig[name]) {
throw new Error('i dont have a command for ' + name); throw new Error('i dont have a command for ' + name);
} }
@ -23764,7 +23765,7 @@ var CommandResult = Errors.CommandResult;
var commandConfig; var commandConfig;
var commands = { var commands = {
execute: function(name, engine, commandObj) { execute: function(vcs, name, engine, commandObj) {
if (!commandConfig[name]) { if (!commandConfig[name]) {
throw new Error('i dont have a command for ' + name); throw new Error('i dont have a command for ' + name);
} }
@ -26333,8 +26334,9 @@ GitEngine.prototype.dispatch = function(command, deferred) {
}); });
try { try {
var vcs = command.get('vcs');
var methodName = command.get('method').replace(/-/g, ''); var methodName = command.get('method').replace(/-/g, '');
GitCommands.commands.execute(methodName, this, this.command); GitCommands.commands.execute(vcs, methodName, this, this.command);
} catch (err) { } catch (err) {
this.filterError(err); this.filterError(err);
// short circuit animation by just setting error and returning // short circuit animation by just setting error and returning

View file

@ -9,7 +9,7 @@ var CommandResult = Errors.CommandResult;
var commandConfig; var commandConfig;
var commands = { var commands = {
execute: function(name, engine, commandObj) { execute: function(vcs, name, engine, commandObj) {
if (!commandConfig[name]) { if (!commandConfig[name]) {
throw new Error('i dont have a command for ' + name); throw new Error('i dont have a command for ' + name);
} }

View file

@ -1733,8 +1733,9 @@ GitEngine.prototype.dispatch = function(command, deferred) {
}); });
try { try {
var vcs = command.get('vcs');
var methodName = command.get('method').replace(/-/g, ''); var methodName = command.get('method').replace(/-/g, '');
GitCommands.commands.execute(methodName, this, this.command); GitCommands.commands.execute(vcs, methodName, this, this.command);
} catch (err) { } catch (err) {
this.filterError(err); this.filterError(err);
// short circuit animation by just setting error and returning // short circuit animation by just setting error and returning