fix router bug with more better way