generic controlelrs refactor