Skip to content

Commit f47fc46

Browse files
authored
chore: fix JavaScript lint errors
PR-URL: stdlib-js#10266 Closes: stdlib-js#10264 Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
1 parent 1e31792 commit f47fc46

File tree

1 file changed

+15
-14
lines changed
  • lib/node_modules/@stdlib/_tools/github/fetch-file/lib

1 file changed

+15
-14
lines changed

lib/node_modules/@stdlib/_tools/github/fetch-file/lib/factory.js

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,21 @@ function factory( filepath, repos, clbk ) {
5656
opts = copy( defaults );
5757
return fetchFile;
5858

59+
/**
60+
* Callback invoked after query completion.
61+
*
62+
* @private
63+
* @param {(Error|null)} error - error object
64+
* @param {Object} results - query results
65+
* @returns {void}
66+
*/
67+
function done( error, results ) {
68+
if ( error ) {
69+
return clbk( error );
70+
}
71+
clbk( null, results );
72+
}
73+
5974
/**
6075
* Fetches a file from one or more repositories.
6176
*
@@ -64,20 +79,6 @@ function factory( filepath, repos, clbk ) {
6479
*/
6580
function fetchFile() {
6681
resolve( filepath, repos, opts, done );
67-
/**
68-
* Callback invoked after query completion.
69-
*
70-
* @private
71-
* @param {(Error|null)} error - error object
72-
* @param {Object} results - query results
73-
* @returns {void}
74-
*/
75-
function done( error, results ) {
76-
if ( error ) {
77-
return clbk( error );
78-
}
79-
clbk( null, results );
80-
}
8182
}
8283
}
8384

0 commit comments

Comments
 (0)