mirror of
https://github.com/SteamDeckHomebrew/decky-loader.git
synced 2026-07-11 18:01:54 +00:00
Grab Plugin path from find_plugin_folder plugin name is not always folder anme (#178)
This commit is contained in:
+3
-4
@@ -48,10 +48,9 @@ class PluginBrowser:
|
|||||||
return False
|
return False
|
||||||
return True
|
return True
|
||||||
|
|
||||||
async def _download_remote_binaries_for_plugin_with_name(self, plugin_name):
|
async def _download_remote_binaries_for_plugin_with_name(self, pluginBasePath):
|
||||||
rv = False
|
rv = False
|
||||||
try:
|
try:
|
||||||
pluginBasePath = path.join(self.plugin_path, plugin_name)
|
|
||||||
packageJsonPath = path.join(pluginBasePath, 'package.json')
|
packageJsonPath = path.join(pluginBasePath, 'package.json')
|
||||||
pluginBinPath = path.join(pluginBasePath, 'bin')
|
pluginBinPath = path.join(pluginBasePath, 'bin')
|
||||||
|
|
||||||
@@ -143,10 +142,10 @@ class PluginBrowser:
|
|||||||
logger.debug("Unzipping...")
|
logger.debug("Unzipping...")
|
||||||
ret = self._unzip_to_plugin_dir(res_zip, name, hash)
|
ret = self._unzip_to_plugin_dir(res_zip, name, hash)
|
||||||
if ret:
|
if ret:
|
||||||
ret = await self._download_remote_binaries_for_plugin_with_name(name)
|
plugin_dir = self.find_plugin_folder(name)
|
||||||
|
ret = await self._download_remote_binaries_for_plugin_with_name(plugin_dir)
|
||||||
if ret:
|
if ret:
|
||||||
logger.info(f"Installed {name} (Version: {version})")
|
logger.info(f"Installed {name} (Version: {version})")
|
||||||
plugin_dir = self.find_plugin_folder(name)
|
|
||||||
if name in self.loader.plugins:
|
if name in self.loader.plugins:
|
||||||
self.loader.plugins[name].stop()
|
self.loader.plugins[name].stop()
|
||||||
self.loader.plugins.pop(name, None)
|
self.loader.plugins.pop(name, None)
|
||||||
|
|||||||
Reference in New Issue
Block a user