[Idea] Modification to Ahoy::DatabaseStore.track_visit
Hello,
I have an idea for a modification.
Basically would like to change Ahoy::DatabaseStore.track_visit to not only create a visit but update a visit.
The use case is simple we are adding a fingerprint to a visit. However, the fingerprint is generated asynchronously, and on some browsers, the visit has been created before the fingerprint is generated. So it needs to be updated. I have changed the Ahoy.js CreateVisit to handle the additional request in the use case when a visit exists.
So it would be helpful to send new/updated data to the server and the visit.
I have made corresponding changes to Ahoy.js to send visit data back.
Is this a good idea? Are there apparent flaws?
If it is something of interest, I can make a pull request...I think.
@jmartyniak hello, what is the result?