xdan / jodit-connectors

Official Jodit connectors
GNU General Public License v2.0
24 stars 18 forks source link

can't find action ''permissions'' #9

Closed kolik236 closed 5 years ago

kolik236 commented 5 years ago

function execute () { $methods = get_class_methods($this);

    if (in_array('action' . ucfirst($this->action), $methods)) {
        $this->accessControl->checkPermission($this->getUserRole(), $this->action);
        $this->response->data =  (object)call_user_func_array([$this, 'action' . $this->action], []);
        error_log($this->getUserRole());
    } else {
        error_log($this->action);
        throw new \Exception('Action "' . $this->action . '" not found', 404);
    }

    $this->response->success = true;
    $this->response->data->code = 220;
    $this->display();
}

{ "success": false, "time": "2019-05-09 14:15:13", "data": { "messages": [ "Action \"permissions\" not found" ], "code": 404 } }

portapipe commented 3 years ago

How did you fix this?