remove responsibility from views to controller