~ refactor controller