Added more logging for invalid commands sent