pkgmgr: Fix games list not being updated after game install
authorrubenwardy <rw@rubenwardy.com>
Wed, 9 Jan 2019 13:14:24 +0000 (13:14 +0000)
committerrubenwardy <rw@rubenwardy.com>
Wed, 9 Jan 2019 13:14:33 +0000 (13:14 +0000)
Fixes #8074

builtin/mainmenu/pkgmgr.lua

index f6015ef7277fa49c4f63ea9c0bd80302ba0e74f2..cea373c9f5e7858d3eb2ab7f446417b9d70c05d6 100644 (file)
@@ -505,7 +505,11 @@ function pkgmgr.install_dir(type, path, basename, targetpath)
                        fgettext("Failed to install $1 to $2", basename, targetpath)
        end
 
-       pkgmgr.refresh_globals()
+       if basefolder.type == "game" then
+               pkgmgr.update_gamelist()
+       else
+               pkgmgr.refresh_globals()
+       end
 
        return targetpath, nil
 end