mirror of
https://github.com/YunoHost/SSOwat.git
synced 2024-09-03 20:06:27 +02:00
[fix] Keep user info in json format
This commit is contained in:
parent
7396d099e6
commit
55063df424
3 changed files with 4 additions and 2 deletions
|
@ -334,6 +334,7 @@ end
|
||||||
|
|
||||||
if hlp.is_logged_in() then
|
if hlp.is_logged_in() then
|
||||||
-- serve ynhpanel files
|
-- serve ynhpanel files
|
||||||
|
serveAsset("/ynh_userinfo.json", "js/ynh_userinfo.js")
|
||||||
serveAsset("/ynh_portal.js", "js/ynh_portal.js")
|
serveAsset("/ynh_portal.js", "js/ynh_portal.js")
|
||||||
serveAsset("/ynh_overlay.css", "css/ynh_overlay.css")
|
serveAsset("/ynh_overlay.css", "css/ynh_overlay.css")
|
||||||
-- serve theme's files
|
-- serve theme's files
|
||||||
|
|
|
@ -538,13 +538,13 @@ function get_data_for(view)
|
||||||
elseif view == "portal.html"
|
elseif view == "portal.html"
|
||||||
or view == "edit.html"
|
or view == "edit.html"
|
||||||
or view == "password.html"
|
or view == "password.html"
|
||||||
or view == "ynhpanel.json" then
|
or view == "ynh_userinfo.json" then
|
||||||
|
|
||||||
-- Invalidate cache before loading these views.
|
-- Invalidate cache before loading these views.
|
||||||
-- Needed if the LDAP db is changed outside ssowat (from the cli for example).
|
-- Needed if the LDAP db is changed outside ssowat (from the cli for example).
|
||||||
-- Not doing it for ynhpanel.json only for performance reasons,
|
-- Not doing it for ynhpanel.json only for performance reasons,
|
||||||
-- so the panel could show wrong first name, last name or main email address
|
-- so the panel could show wrong first name, last name or main email address
|
||||||
if view ~= "ynhpanel.json" then
|
if view ~= "ynh_userinfo.json" then
|
||||||
delete_user_info_cache(user)
|
delete_user_info_cache(user)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
1
portal/assets/js/ynh_userinfo.json
Normal file
1
portal/assets/js/ynh_userinfo.json
Normal file
|
@ -0,0 +1 @@
|
||||||
|
{}
|
Loading…
Add table
Reference in a new issue