@@ -300,6 +300,8 @@ function store.load()
300300 package .url = base_url .. " /packages/" ..
301301 package .author .. " /" .. package .name ..
302302 " /releases/" .. package .release .. " /download/"
303+
304+ package .id = package .author .. " /" .. package .name
303305 end
304306
305307 store .packages = store .packages_full
@@ -314,38 +316,38 @@ function store.update_paths()
314316 pkgmgr .refresh_globals ()
315317 for _ , mod in pairs (pkgmgr .global_mods :get_list ()) do
316318 if mod .author then
317- mod_hash [mod .name ] = mod
319+ mod_hash [mod .author .. " / " .. mod . name ] = mod
318320 end
319321 end
320322
321323 local game_hash = {}
322324 pkgmgr .update_gamelist ()
323325 for _ , game in pairs (pkgmgr .games ) do
324326 if game .author then
325- game_hash [game .id ] = game
327+ game_hash [game .author .. " / " .. game . id ] = game
326328 end
327329 end
328330
329331 local txp_hash = {}
330332 for _ , txp in pairs (pkgmgr .get_texture_packs ()) do
331333 if txp .author then
332- txp_hash [txp .name ] = txp
334+ txp_hash [txp .author .. " / " .. txp . name ] = txp
333335 end
334336 end
335337
336338 for _ , package in pairs (store .packages_full ) do
337339 local content
338340 if package .type == " mod" then
339- content = mod_hash [package .name ]
341+ content = mod_hash [package .id ]
340342 elseif package .type == " game" then
341- content = game_hash [package .name ]
343+ content = game_hash [package .id ]
342344 elseif package .type == " txp" then
343- content = txp_hash [package .name ]
345+ content = txp_hash [package .id ]
344346 end
345347
346- if content and content . author == package . author then
348+ if content then
347349 package.path = content .path
348- package .installed_release = content .release
350+ package .installed_release = content .release or 0
349351 else
350352 package.path = nil
351353 end
0 commit comments