There is a bug in the regular expression used in compressIdentifier: the numeric part of the identifier match is optional. If an identifier such as em or px is encountered without a number before the unit, num = m[1] is undefined and calling num.match(...) throws a TypeError.
Fixed by making the first matching group required, as there's nothing to compress if there's no value.
There is a bug in the regular expression used in compressIdentifier: the numeric part of the identifier match is optional. If an identifier such as
em
orpx
is encountered without a number before the unit,num = m[1]
is undefined and callingnum.match(...)
throws aTypeError
.Fixed by making the first matching group required, as there's nothing to compress if there's no value.