started to extract controller methods