packing everything into controller