Refactored console class