You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On cilentside i am able to get 401 error code but i can't get the error message.
I get {"success":true,"message":null,"messages":null,"data":null} or empty.
I would like to have a response similar to this
{"success":true,"message":null,"messages":null,"data":{
'message' => 'error message'
}}.
How can I return error code using this plugin?
I did like this but it doesn't work exactly.
http_response_code(401);
return json_encode(array(
'message' => 'error message'
));
On cilentside i am able to get 401 error code but i can't get the error message.
I get {"success":true,"message":null,"messages":null,"data":null} or empty.
I would like to have a response similar to this
{"success":true,"message":null,"messages":null,"data":{
'message' => 'error message'
}}.