shareandcharge / sharecharge-api

HTTP webserver for the Share&Charge e-Mobility Network
0 stars 0 forks source link

bad status code returned on error #8

Open AndreiD opened 6 years ago

AndreiD commented 6 years ago

upon deleting with an invalid location id I get the error

time="2018-08-16T20:54:25+03:00" level=info msg="PUT Request Returned >>> Location object not valid. Ensure location follows the OCPI model" time="2018-08-16T20:54:58+03:00" level=info msg="DELETE Request Returned >>> <!DOCTYPE html>\n<html lang=\"en\">\n\n<meta charset=\"utf-8\">\nError\n\n\n

Cannot DELETE /api/store/locations/0x34342e3030353431342c2d37312e343932333738
\n\n\n"

### but the response code is 200.

Please change it to 400 Bad Request or 406 Not Acceptable....