Created private methods in IOController for better structure.