updated router logic/regex