docs: private String getState(CmsPublishJobFinished publishJob) {
  
          byte[] reportBytes = null;
          try {
              reportBytes = OpenCms.getPublishManager().getReportContents(publishJob);
          } catch (CmsException e) {
              //Can't read report -> error
              return STATE_ERROR;
          }
          if (reportBytes != null) {
              String report = new String(reportBytes);
              if (report.indexOf("<span class='err'>") > -1) {
                  //Report contains error span
                  return STATE_ERROR;
  
              }
              if (report.indexOf("<span class='warn'>") > -1) {
                  //Report contains warning span
                  return STATE_WARNING;
  
              }
          }
          //no warning or error state detected -> ok
          return STATE_OK;
  
      }