Some refactoring and improvments for Router class.