GNOME Bugzilla – Bug 771449
Do not show an update for apps whose latest flatpak commit is NULL
Last modified: 2016-12-02 14:29:04 UTC
The logic for setting an app as updatable works by comparing the current commit of an app with the latest one available. However, if an app no longer exists in its remote, then the latest commit is being set as NULL, thus resulting in a wrong update for the app in GNOME Software. I have also filed an issue on Flatpak [1] to see if that NULL return is something intentional or not. So keep in mind that if it gets changed in Flatpak, then the patch I am attaching here is no longer necessary. [1] https://github.com/flatpak/flatpak/issues/309
Created attachment 335571 [details] [review] Do not show an update for apps whose latest flatpak commit is NULL The logic for setting an app as updatable works by comparing the current commit of an app with the latest one available. However, if an app no longer exists in its remote, then the latest commit is being set as NULL, thus resulting in a wrong update for the app in GNOME Software. This patch simply checks if the latest commit of an app is not NULL before comparing the commits in question.
I think this is probably a good idea regardless, but I'd change the debug message for the NULL case (i.e. have two 'if' statements)
Created attachment 341239 [details] [review] Do not show an update for apps whose latest flatpak commit is NULL
Fixed in master.