Added status code to logging (Why was this not in there before doh)