Hi,
when passing URL params to the api, the Api->rest() does not work as supposed. Furthermore, if the last part of the pattern is a variable (e.g. :id), the URL params are added to this variable
pattern setup:
$this->rest('/bookings', new Booking($this->app->db));
This request is not recoqnized:
www.mydomain.com/api/bookings?access_token=123456
DELETE www.mydomain.com/api/bookings/3?access_token=123456
=> id which should be 3 becomes 3?access_token=123456
My proposal:
remove all URL params from $this->path and store them seperately. Tested, works for the 2 cases above.
Hi, when passing URL params to the api, the Api->rest() does not work as supposed. Furthermore, if the last part of the pattern is a variable (e.g. :id), the URL params are added to this variable
My proposal: