code: private void buildBaseReport() throws JSONException {
          report = new JSONObject();
          JSONObject dates = new JSONObject();
          dates.put("date.system", created);
          dates.put("date", new Date(created).toString());
          dates.put("locale", Locale.getDefault());
          report.put("dates", dates);
          if (message != null) {
              report.put("message", message);
          }
          if (err != null) {
              report.put("error", err.getMessage());
              report.put("stackTrace",LogHelper.getStackTraceString(err));
              if (err.getCause() != null) {
                  report.put("cause", err.getCause().getMessage());
                  report.put("cause.stackTrace",LogHelper.getStackTraceString(err.getCause()));
              }
  
          }
      }
docs: Adds the report header to the report (dates, locale, message, errors
  ...).
  @param report the report
  @throws JSONException if the data cannot be added