mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
Merge pull request #1122 from YunoHost/avoid_calling_app_list_in_user_permission_list
[mod] avoid calling app_list in user_permission_list
This commit is contained in:
commit
968a707a4c
1 changed files with 2 additions and 2 deletions
|
@ -51,7 +51,7 @@ def user_permission_list(short=False, full=False, ignore_system_perms=False, abs
|
||||||
"""
|
"""
|
||||||
|
|
||||||
# Fetch relevant informations
|
# Fetch relevant informations
|
||||||
from yunohost.app import app_setting, app_list
|
from yunohost.app import app_setting, _installed_apps
|
||||||
from yunohost.utils.ldap import _get_ldap_interface, _ldap_path_extract
|
from yunohost.utils.ldap import _get_ldap_interface, _ldap_path_extract
|
||||||
ldap = _get_ldap_interface()
|
ldap = _get_ldap_interface()
|
||||||
permissions_infos = ldap.search('ou=permission,dc=yunohost,dc=org',
|
permissions_infos = ldap.search('ou=permission,dc=yunohost,dc=org',
|
||||||
|
@ -60,7 +60,7 @@ def user_permission_list(short=False, full=False, ignore_system_perms=False, abs
|
||||||
'URL', 'additionalUrls', 'authHeader', 'label', 'showTile', 'isProtected'])
|
'URL', 'additionalUrls', 'authHeader', 'label', 'showTile', 'isProtected'])
|
||||||
|
|
||||||
# Parse / organize information to be outputed
|
# Parse / organize information to be outputed
|
||||||
apps = [app["id"] for app in app_list()["apps"]]
|
apps = sorted(_installed_apps())
|
||||||
apps_base_path = {app: app_setting(app, 'domain') + app_setting(app, 'path')
|
apps_base_path = {app: app_setting(app, 'domain') + app_setting(app, 'path')
|
||||||
for app in apps
|
for app in apps
|
||||||
if app_setting(app, 'domain') and app_setting(app, 'path')}
|
if app_setting(app, 'domain') and app_setting(app, 'path')}
|
||||||
|
|
Loading…
Add table
Reference in a new issue