Welcome Guest, Not a member yet? Register   Sign In
User authentication
#5

That was my thought initially, but I've tried this and an exception is thrown. To me, it's the logical place to do this, but the exception is thrown by a system file:

Code:
    "title": "ErrorException",
    "type": "ErrorException",
    "code": 500,
    "message": "Undefined property: App\\Filters\\ApiBaseFilter::$response",
    "file": "\\vendor\\codeigniter4\\framework\\system\\API\\ResponseTrait.php",
    "line": 128,

This seems to be looking for a $response in the filter, but because it's the before function, there's only a request.

I have found a workaround, but I'm wondering if this is intended behaviour? And if it is, how should the API Response Trait actually be used?
Reply


Messages In This Thread
User authentication - by Parker1090 - 03-08-2020, 08:28 AM
RE: User authentication - by includebeer - 03-08-2020, 11:34 AM
RE: User authentication - by Parker1090 - 03-13-2020, 05:45 AM
RE: User authentication - by includebeer - 03-14-2020, 06:53 AM
RE: User authentication - by Parker1090 - 03-16-2020, 01:27 PM



Theme © iAndrew 2016 - Forum software by © MyBB