note about trait, and add check on request
authorAlan <alan@roojs.com>
Mon, 22 Jan 2024 05:16:44 +0000 (13:16 +0800)
committerAlan <alan@roojs.com>
Mon, 22 Jan 2024 05:16:44 +0000 (13:16 +0800)
Pman.php
Pman/Roo.php

index 478b70e..aa20bf1 100644 (file)
--- a/Pman.php
+++ b/Pman.php
@@ -1086,7 +1086,7 @@ class Pman extends HTML_FlexyFramework_Page
         $reported = true;
         
         $out = (is_a($ex,'Exception') || is_a($ex, 'Error') ? $ex->getMessage() : $ex->toString()) .
-            ' ' . $_SERVER['REQUEST_METHOD'] . ' ' .
+            ' ' . (empty($_SERVER['REQUEST_METHOD']) ? 'cli' :  $_SERVER['REQUEST_METHOD'] ) . ' ' .
             (empty($_SERVER['REQUEST_URI'])     ? 'No URL' : $_SERVER['REQUEST_URI']) .
               ' ' .    (empty($POST) ? '' : file_get_contents('php://input')) ;
         
index 05dfb94..35869a1 100644 (file)
@@ -42,6 +42,14 @@ require_once 'Pman.php';
 
 class Pman_Roo extends Pman
 {
+    
+   /* EVENTUALLY - move this stuff here..
+    * use Pman_Core_RooTrait,
+        Pman_Core_RooGetTrait,
+        Pman_Core_RooPostTrait,
+        Pman_Core_RooJsonOutputTrait;
+    */
+    
     /**
      * if set to an array (when extending this, then you can restrict which tables are available
      */