Closed ash-jc-allen closed 4 months ago
I've opted to make the migration an optional (yet recommended) step in the upgrade guide.
Just so that I can sleep easy at night without worrying that I've messed up anyone's data, I'll let the developer explicitly make the decision to convert the data themselves haha! I'm not sure if this is the right decision, but I couldn't quite make my mind up.
So I'll close this one for now 🙂
This PR piggy backs off the back off #244 to solve issue #243.
Currently, if the user agent parser can't detect data from the user agent string, the fields will be stored as
false
in theshort_url_visits
table. For example, if we can't detect the visitor's browser version, then thebrowser_version
field will be saved asfalse
.As of Short URL v8 (to be released shortly), this behaviour has slightly changed. Instead, we'll use
null
rather thanfalse
.This PR uses @stevebauman's proposed database migration that will update any existing rows that are using
false
to now benull
.I'm going to sit on this one for a day or so and try to get some other opinions. I'm worried about corrupting anyone's data! 🤯