fix for crash when exiting before a asset finishes loading