Add an optional route param to goto function