Better error reporting
authorAlan <alan@roojs.com>
Fri, 8 Sep 2023 05:15:34 +0000 (13:15 +0800)
committerAlan <alan@roojs.com>
Fri, 8 Sep 2023 05:15:34 +0000 (13:15 +0800)
GroupRights.php
Signup.php

index 6275f2c..0dbd455 100644 (file)
@@ -12,7 +12,7 @@ class Pman_Admin_GroupRights extends Pman
         parent::getAuth(); // load company!
         $au = $this->getAuthUser();
         if (!$au) {
-            $this->jerr("Not authenticated", array('authFailure' => true));
+            $this->jerror("LOGIN-NOAUTH", "Not authenticated", array('authFailure' => true));
         }
         
         if ($au->company()->comptype !='OWNER') {
index 4edf7ac..d06a711 100644 (file)
@@ -8,7 +8,7 @@ class Pman_Admin_Signup extends Pman
         parent::getAuth(); // load company!
         $au = $this->getAuthUser();
         if (!$au) {
-            $this->jerr("Not authenticated", array('authFailure' => true));
+            $this->jerror("LOGIN-NOAUTH", "Not authenticated", array('authFailure' => true));
         }
         $this->authUser = $au;
         if ($au->company()->comptype != 'OWNER') {