Fixed exception being thrown in Application.php