more quote identeiifers fixessss
[Pman.Core] / JavascriptError.php
index 93ff3bc..11f4deb 100644 (file)
@@ -1,5 +1,7 @@
 <?php
+// FIXME... auth errors need ratelimiting 
 
+require_once 'Pman.php';
 
 class Pman_Core_JavascriptError extends Pman {
     
@@ -9,12 +11,9 @@ class Pman_Core_JavascriptError extends Pman {
         parent::getAuth(); // load company!
         $au = $this->getAuthUser();
        
-        if (!$au) {
-            // fixme... this needs to be rate limited....
-            $this->jerr("Not authenticated", array('authFailure' => true));
-        }
-        if (!$au->pid()   ) { // not set up yet..
-            $this->jerr("Not authenticated", array('authFailure' => true));
+        if (!$au || !$au->pid()) {
+            
+            die("authenticated Users only");
         }
         
         
@@ -22,6 +21,18 @@ class Pman_Core_JavascriptError extends Pman {
         return true;
     }
     
+    function get($v, $opts=array())
+    {
+        die("invalid url");
+    }
+    
+    function post($v)
+    {
+         
+        $this->addEvent("JSERROR", false,$_REQUEST['msg']);
+        $this->jok("OK");
+    }
+