yeah, but it's a weird way to do it.

It's probably not the fastest way to do that check - given that
it parses a string, then compares it with another string, then parses that string again (that is the schemantics at least) js perf is mysterious, so you'd have to benchmark it.

So anyway, it's probably good to remove this line anyway.