if (log.isWarnEnabled()) log.warn("Error cancelling session ("+me+")" + qId + " at " +
if (log != null && log.isWarnEnabled()) log.warn("Error cancelling session ("+me+")" + qId + " at " +
  private void cancelSession (Element root) throws Exception {    String qId = root.getAttribute("query_id");    BBSession match = findSessionById(qId);    if (match != null)      match.cancel();    else {      String type = root.getNodeName();      if (type.equals("pull_request") || type.equals("push_request"))        if (log.isWarnEnabled()) log.warn("Error cancelling session ("+me+")" + qId + " at " +          getAgentIdentifier().getAddress());    }  }