File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,12 +5,6 @@ var lookupWrapper = require("./util/lookupWrapper");
55var Remote = NodeGit . Remote ;
66var setCallbacks = Remote . prototype . setCallbacks ;
77
8- Remote . prototype . setCallbacks = function ( callbacks ) {
9- callbacks = normalizeOptions ( callbacks , NodeGit . RemoteCallbacks ) ;
10-
11- return setCallbacks . call ( this , callbacks ) ;
12- } ;
13-
148/**
159 * Retrieves the remote by name
1610 * @param {Repository } repo The repo that the remote lives in
@@ -20,4 +14,10 @@ Remote.prototype.setCallbacks = function(callbacks) {
2014 */
2115Remote . lookup = lookupWrapper ( Remote ) ;
2216
17+ Remote . prototype . setCallbacks = function ( callbacks ) {
18+ callbacks = normalizeOptions ( callbacks , NodeGit . RemoteCallbacks ) ;
19+
20+ return setCallbacks . call ( this , callbacks ) ;
21+ } ;
22+
2323module . exports = Remote ;
Original file line number Diff line number Diff line change @@ -83,12 +83,8 @@ describe("Remote", function() {
8383 var repository = this . repository ;
8484
8585 return Remote . create ( repository , "origin3" , url )
86- . then ( function ( ) {
87- } )
8886 . then ( function ( remote ) {
89- remote . delete ( ) ;
90- } )
91- . then ( function ( ) {
87+ Remote . delete ( repository , "origin3" ) ;
9288 return Remote . lookup ( repository , "origin3" ) ;
9389 } )
9490 . then ( Promise . reject , Promise . resolve ) ;
@@ -132,8 +128,11 @@ describe("Remote", function() {
132128 return this . repository . fetchAll ( {
133129 credentials : function ( url , userName ) {
134130 return NodeGit . Cred . sshKeyFromAgent ( userName ) ;
131+ } ,
132+ certificateCheck : function ( ) {
133+ return 1 ;
135134 }
136- } , true ) ;
135+ } ) ;
137136 } ) ;
138137
139138} ) ;
You can’t perform that action at this time.
0 commit comments