jwt-auth
jwt-auth copied to clipboard
Device parameter is not parsed from request body if sent with 'content-type: json'.
Discovered during #33
Problem
- When sending REST parameters as a JSON object together with a
Content-Type: jsoninstead ofmultipart/form-data, then thedeviceparameter is not handled; i.e., the device is not registered and does not appear in the user account.
Cause
- The code directly accesses
$_POST['device']instead of retrieving the request parameter fromWP_REST_Request.