Updated chat functions and included missing debug level.