PROJ-151: Changed application_controller.rb for a more elegant solution