this makes it match on new only, but still not sure why we need to run it via JS in the first place.