Skip to content

Commit 226751c

Browse files
committed
Make getFilePath private.
1 parent bb5ba24 commit 226751c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/resource-mapper.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ class ResourceMapper {
4444
// Maps the request for a given resource and representation format to a server file
4545
// When searchIndex is true and the URL ends with a '/', and contentType includes 'text/html' indexFilename will be matched.
4646
async mapUrlToFile ({ url, contentType, createIfNotExists, searchIndex = true }) {
47-
let fullFilePath = this.getFilePath(url)
47+
let fullFilePath = this._getFilePath(url)
4848
let isIndex = searchIndex && fullFilePath.endsWith('/')
4949
let path
5050

@@ -101,7 +101,7 @@ class ResourceMapper {
101101
}
102102

103103
async getRepresentationUrlForResource (resourceUrl) {
104-
let fullFilePath = this.getFilePath(resourceUrl)
104+
let fullFilePath = this._getFilePath(resourceUrl)
105105
let isIndex = fullFilePath.endsWith('/')
106106

107107
// Append index filename if the URL ends with a '/'
@@ -146,7 +146,7 @@ class ResourceMapper {
146146
}
147147

148148
// Determine the full file path corresponding to a URL
149-
getFilePath (url) {
149+
_getFilePath (url) {
150150
const { pathname, hostname } = this._parseUrl(url)
151151
const fullFilePath = decodeURIComponent(`${this.getBasePath(hostname)}${pathname}`)
152152
if (fullFilePath.indexOf('/..') >= 0) {

0 commit comments

Comments
 (0)