mirror of
https://github.com/bower/bower.git
synced 2026-04-24 03:00:19 -04:00
More succinct.
This commit is contained in:
@@ -23,9 +23,7 @@ GitRemoteResolver.prototype._checkout = function (resolution) {
|
||||
// Because a commit is not a nammed ref, there's no better solution
|
||||
if (resolution.type === 'commit') {
|
||||
return cmd('git', ['clone', this._source, '.'], { cwd: dir })
|
||||
.then(function () {
|
||||
return cmd('git', ['checkout', resolution.commit], { cwd: dir });
|
||||
});
|
||||
.then(cmd.bind(cmd, 'git', ['checkout', resolution.commit], { cwd: dir }));
|
||||
// Otherwise we are checking out a named ref so we can optimize it
|
||||
} else {
|
||||
branch = resolution.tag || resolution.branch;
|
||||
|
||||
Reference in New Issue
Block a user