general fixes & failsafes