Fixed NullPointer if model does not exist