Skip to content

Commit ffc948b

Browse files
committed
made the baseURI available on the manifest
This is needed in aiur, and removes some akward workarounds there.
1 parent 2a19f94 commit ffc948b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/manifest.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ exports.Manifest = class Manifest {
1212
}
1313
this.webRoot = webRoot = resolvePath(webRoot || "./", referenceDir,
1414
{ enforceRelative: true });
15+
this.baseURI = baseURI || "/";
1516

1617
if(target) {
1718
this.filepath = resolvePath(target, referenceDir, { enforceRelative: true });
@@ -27,8 +28,7 @@ exports.Manifest = class Manifest {
2728
if(value) {
2829
this.valueTransform = value;
2930
} else {
30-
baseURI = baseURI || "/";
31-
this.valueTransform = filepath => baseURI + path.relative(webRoot, filepath);
31+
this.valueTransform = filepath => this.baseURI + path.relative(webRoot, filepath);
3232
}
3333
}
3434

0 commit comments

Comments
 (0)