When trying to edit a record which I created in a just made with command php artisan ninja:make-module, I get an error ‘Trying to get property of non-object’. I can create and delete the records.
2020-11-09 18:52:41] production.ERROR: ErrorException [0] : /var/www/html/ninja/Modules/Kunstenaars/Http/Controllers/KunstenaarsController.php [Line 90] => Trying to get property of non-object {“context”:“PHP”,“user_id”:3,“account_id”:“3”,“user_name”:"…",“method”:“GET”,“user_agent”:“Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:82.0) Gecko/20100101 Firefox/82.0”,“locale”:“nl”,“ip”:…",“count”:10,“is_console”:“no”,“is_api”:“no”,“db_server”:“mysql”,“url”:“kunstenaars/2/edit”}
Line 90 in KunstenaarsController.php is referring to $request->entity(). When I do a dump on that, I get a NULL. In the database there is a record with 2 as id. What is going wrong?
I am on a Self-host version, with PHP70 on CentOS 7.
Thanks.