refactor: simplify isPresent(x) ? x : y
to x || y
(#12166)
Closes #12166
This commit is contained in:

committed by
Tobias Bosch

parent
bdcf46f82e
commit
d972d82354
@ -476,7 +476,7 @@ export class CssScanner {
|
||||
var index: number = this.index;
|
||||
var column: number = this.column;
|
||||
var line: number = this.line;
|
||||
errorTokenValue = isPresent(errorTokenValue) ? errorTokenValue : String.fromCharCode(this.peek);
|
||||
errorTokenValue = errorTokenValue || String.fromCharCode(this.peek);
|
||||
var invalidToken = new CssToken(index, column, line, CssTokenType.Invalid, errorTokenValue);
|
||||
var errorMessage =
|
||||
generateErrorMessage(this.input, message, errorTokenValue, index, line, column);
|
||||
|
Reference in New Issue
Block a user