support relative paths for backward compatibility; fixes #61088

This commit is contained in:
Andre Weinand 2018-10-17 23:11:17 +02:00
parent 4f09f1aa4a
commit 613aa464ae

View file

@ -56,9 +56,8 @@ export class Source {
if (paths.isAbsolute_posix(path) || paths.isAbsolute_win32(path)) {
this.uri = uri.file(path);
} else {
// path is relative
// should not happen because relative paths always have a sourceReference > 0
console.error('cannot handle relative paths without sourceReference');
// path is relative: this is not supported but if it happens we create a bogus uri for backward compatibility
this.uri = uri.file(path);
}
}
}