config migration in source code; config page is not needed anymore
[iserv-mod-error-reporter.git] / src / index.php
index 9a9f7d7..0bae2b6 100644 (file)
@@ -51,7 +51,7 @@ $strError = "";
 
 PageBlue(_c("error-reporter:Report an error"), "mod_error-reporter");
 
-if(!$cfgErrors->userHasAccess()) {
+if(!erConfig::userHasAccess()) {
   printf("<p class='err'>%s</p>\n", ER_ERROR_ACCESS_DENIED);
   _PageBlue();
   exit();
@@ -75,7 +75,7 @@ if($getAction == "delete" and isset($getUid)) {
         _c("error-reporter:The specified error report does not exist!"));
       Option(_("Back"), null, "href='".$_SERVER["PHP_SELF"]."'", "back");
     } else {
-      if($cfgErrors->userIsAdmin() or $doc->userIsOwner($getUid)) {
+      if(erConfig::userIsAdmin() or $doc->userIsOwner($getUid)) {
         echo sprintf("<form action='%s' method='post'>\n", 
           $view->getDeleteURL($getUid));
         echo sprintf("<p>%s</p>", _c("error-reporter:You are about to delete ".
@@ -109,7 +109,8 @@ if(($getAction == "submit" and $postSubmit == _c("error-reporter:Submit")))
   } else {
     // Write to database
     $nNewUid = null;
-    $er = new erErrorReport(time(), $_SESSION["act"], $postMachine, $postText, $postHidden == "true");
+    $er = new erErrorReport(time(), $_SESSION["act"], $postMachine, $postText,
+      $postHidden == "true");
     try {
       $nNewUid = $doc->writeErrorReport($er); 
     } catch(Exception $e) {
This page took 0.022766 seconds and 4 git commands to generate.