fixed deprecated preg_replace in router