OCSInventory-NG / OCSInventory-Server

Communication server of OCS Inventory
http://www.ocsinventory-ng.org/
GNU General Public License v2.0
344 stars 139 forks source link

OCS Api Computer pagination return "null" instead of null #328

Closed dust63 closed 1 year ago

dust63 commented 3 years ago

OCS Inventory informations

Ocs server version : 2.8

Problem's description

when you call the route of /computer&start=XXX&limit=XXX if you riched the end of paignation, OCS api return a string "null". It's not a correct way. You should send null (no data) instead of a literral because it's a json object that we attempt. The best approach for me in this case is to sent only a 204 status code to prevent client that no data are available.

Regards.

charleneauger commented 1 year ago

Hi @dust63 ,

This problem is fixed in the latest versions.

Best regards, Charlene