@@ -29,7 +29,7 @@ def read_user_config():
29
29
30
30
def read_manifests_in_subdirs (parent_directory , userConfig , category = None ):
31
31
manifests = []
32
- # addons = userConfig.get('addons')
32
+ addons = userConfig .get ('addons' )
33
33
try :
34
34
subdirs = next (os .walk (parent_directory ))[1 ]
35
35
except Exception as e :
@@ -43,7 +43,7 @@ def read_manifests_in_subdirs(parent_directory, userConfig, category=None):
43
43
with open (manifest_path , 'r' ) as file :
44
44
try :
45
45
manifest = yaml .safe_load (file )
46
- # manifest['installed'] = subdir in userConfig['addons']
46
+ manifest ['installed' ] = subdir in addons # userConfig['addons']
47
47
# Filter by category if specified
48
48
if category == "system" :
49
49
# Ensure 'system' key exists and is boolean True
@@ -84,8 +84,8 @@ if True: #len(user) > 0:
84
84
addons = read_manifests_in_subdirs (ADDONS_PATH ,userConfig ,category )
85
85
response ['result' ] = addons
86
86
response ['userConfig' ] = userConfig
87
- # response['success'] = True
88
- # response['total'] = len(addons)
87
+ response ['success' ] = True
88
+ response ['total' ] = len (addons )
89
89
# call function to unmount the loader by calling the following bash /usr/bin/rr-loaderdisk.sh unmountLoaderDisk
90
90
unmountLoader ()
91
91
except Exception as e :
0 commit comments