added a debug_msg to tidy things up