<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def log_exceptions(self, c, broker):
 """Gets exceptions to be logged and sends to logit function to be logged to syslog"""


        if c in broker.exceptions:
            ex = broker.exceptions.get(c)
            ex = "Exception in {0} - {1}".format(dr.get_name(c), str(ex))
            self.logit(ex, self.pid, self.user, "insights-run", logging.ERROR)