Fix bug in StateManager where a state's update function might not get called if it has an empty preload function