*Hopefully* fix recent errors and crashes