Skip to content

Commit 125944a

Browse files
Change assert to allow blank strings in global aliases (#1177)
1 parent 08075c6 commit 125944a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/program.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -1048,7 +1048,8 @@ export class Program extends DiagnosticEmitter {
10481048
// TODO: for (let [alias, name] of globalAliases) {
10491049
for (let _keys = Map_keys(globalAliases), i = 0, k = _keys.length; i < k; ++i) {
10501050
let alias = unchecked(_keys[i]);
1051-
let name = assert(globalAliases.get(alias));
1051+
let name = changetype<string>(globalAliases.get(alias));
1052+
assert(name != null);
10521053
if (!name.length) continue; // explicitly disabled
10531054
let firstChar = name.charCodeAt(0);
10541055
if (firstChar >= CharCode._0 && firstChar <= CharCode._9) {

0 commit comments

Comments
 (0)