File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
cmk/gui/openapi/api_endpoints/icon Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change 2323 DomainObjectModel ,
2424)
2525from cmk .gui .openapi .restful_objects .constructors import collection_href
26- from cmk .gui .theme .current_theme import theme
26+ from cmk .gui .theme import make_theme
27+ from cmk .gui .userdb import load_custom_attr
2728from cmk .gui .watolib .icons import all_available_icon_data
2829
2930
@@ -52,6 +53,10 @@ class IconCollectionModel(DomainObjectCollectionModel):
5253
5354def list_icons_v1 (api_context : ApiContext ) -> IconCollectionModel :
5455 """Show all icons."""
56+ theme = make_theme (validate_choices = False )
57+ theme .from_config (api_context .config .ui_theme )
58+ if user_id := api_context .user_id :
59+ theme .set (load_custom_attr (user_id = user_id , key = "ui_theme" , parser = str ))
5560 return IconCollectionModel (
5661 domainType = "icon" ,
5762 id = "all" ,
You can’t perform that action at this time.
0 commit comments