tomyvi/php-tracks-recorder

less data points sent by client

Opened this issue · 0 comments

Thanks for posting this project. Great work.

My owntrack is only providing these fields:
{"batt":85,"lon":-71.xxxx,"acc":65,"p":100.028526,"vac":10,"lat":42.xxxx,"topic":"owntracks/mqtt/sjf_iphone","t":"u","conn":"w","tst":1541,"alt":100,"_type":"location","tid":"sf"}

and is missing these: cog, desc, event, rad. So database fails to write and code returns 500 to client.

It would be best to change the code so that each field is initialized to null/false/blank that way the db will write correctly if fields are not sent by client and won't fail.