KartulUdus / PoracleJS

NodeJS application for PokémonGo WebHook Discord alarms

Home Page:https://kartuludus.github.io/PoracleJS/#/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Areas with spaces in do not get notifications

georgeherby opened this issue · comments

Expected Behavior

I would expect that if I used an area with a space in like St Helens i would get an alert.

Current Behavior

I do not get alerts for areas that have a space in them

Possible Solution

After a quick chat with Jabes it appears that areas with space get saved into the database with a _ but the query to that checks for humans does not return these areas as the query is not using the _ eg `humans.area like '%"langley st marys"%' or humans.area like '%"langley st marys"%'``

I manually changed the records in the DB from st_marys to st marys and i now get alerts for the area.

I could change the area.js to not add in the _ when areas are being insert but this would require bbdoc to change PoracleWeb too as that has a lot of logic around matching names in the db to the geofence file.

Confirmed - the change is the one you outlined the database should have the space in
area.js needs to be altered
I am happy to do this, just the multilang PR changes a bunch of stuff so will make the change either after that or in that branch

This looks like it has now been resolved as part of the multilang PR

Now fixed