add getBeforeController and getBeforeAction to route