<?php
// FIXME... auth errors need ratelimiting
+require_once 'Pman.php';
+
class Pman_Core_JavascriptError extends Pman {
parent::getAuth(); // load company!
$au = $this->getAuthUser();
- if (!$au) {
+ if (!$au || !$au->pid()) {
- $this->jerr("Not authenticated", array('authFailure' => true));
- }
- if (!$au->pid() ) { // not set up yet..
- $this->jerr("Not authenticated", array('authFailure' => true));
+ die("authenticated Users only");
}
return true;
}
+ function get($v, $opts=array())
+ {
+ die("invalid url");
+ }
- function get()
+ function post($v)
{
- $this->jerror("JSERROR", false, $_REQUEST['msg']);
-
-
-
+
+ $this->addEvent("JSERROR", false,$_REQUEST['msg']);
+ $this->jok("OK");
}