Skip to content

Commit

Permalink
Fix offline resolution
Browse files Browse the repository at this point in the history
  • Loading branch information
Maël Nison committed May 3, 2017
1 parent 0b3c443 commit f1be296
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/fetchers/tarball-fetcher.js
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ export default class TarballFetcher extends BaseFetcher {
async _fetch(): Promise<FetchedOverride> {
const urlParse = url.parse(this.reference);

if (urlParse.protocol === null && urlParse.pathname.match(/^\.\.?[\/\\]/)) {
if (urlParse.protocol === null && urlParse.pathname.match(/^(?=(?:\.{1,2}|[a-z]:)?[\\\/])/i)) {
return await this.fetchFromLocal(this.reference);
}

Expand Down

0 comments on commit f1be296

Please sign in to comment.