Skip to content

Commit 21371e7

Browse files
committed
Inline method
1 parent 7f032d6 commit 21371e7

File tree

3 files changed

+3
-6
lines changed

3 files changed

+3
-6
lines changed

lib/github.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,6 @@ var path = require('path');
44
var findGit = require('../lib/git/find_git');
55
var getGithubURLPrefix = require('../lib/git/url_prefix');
66

7-
function getFileRoot(file) {
8-
return path.dirname(findGit(file));
9-
}
10-
117
/**
128
* Attempts to link code to its place on GitHub.
139
*
@@ -16,7 +12,7 @@ function getFileRoot(file) {
1612
* @return {Object} comment with github inferred
1713
*/
1814
module.exports = function (comment) {
19-
var root = getFileRoot(comment.context.file);
15+
var root = path.dirname(findGit(comment.context.file));
2016
var urlPrefix = getGithubURLPrefix(root);
2117
var fileRelativePath = comment.context.file.replace(root + path.sep, '')
2218
.split(path.sep)

lib/hierarchy.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ var hasOwnProperty = Object.prototype.hasOwnProperty;
55
/**
66
* Pick only relevant properties from a comment to store them in
77
* an inheritance chain
8-
* @param {Object} comment
8+
* @param {Object} comment a parsed comment
99
* @returns {Object} reduced comment
1010
* @private
1111
*/

lib/parse.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -320,6 +320,7 @@ function flattenMarkdownDescription(result, tag, key) {
320320
* @param {Object} result comment
321321
* @param {Object} tag parsed tag
322322
* @param {string} key tag
323+
* @returns {undefined} operates through side effects
323324
* @private
324325
*/
325326
function flattenKindShorthand(result, tag, key) {

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy