Added error logging for exceptions

I appreciate the feedback but I'm so very busy that I'm literally just trying to get anything onto live to try and understand what's fucking up at this point. I'll almost certainly improve this later (it's c&p straight from another project). Please don't think I don't appreciate the comments because I do :+1: