liquid_feedback_frontend

view env/util/is_profile_field_locked.lua @ 1858:3d1f0464a3ea

Handle missing ldap.member.allowed function
author bsw
date Tue Sep 20 17:35:29 2022 +0200 (20 months ago)
parents 32cc544d5a5b
children
line source
1 function util.is_profile_field_locked(member, field_name)
2 if member.authority == "ldap" then
3 if config.ldap.member.locked_profile_fields and config.ldap.member.locked_profile_fields[field_name]
4 or field_name == "login"
5 or field_name == "password"
6 then
7 return true
8 end
9 end
11 if member.authority and string.sub(member.authority, 1, 7) == "oauth2_" then
12 if field_name == "login" or field_name == "password" or field_name == "notify_email" then
13 return true
14 end
15 end
17 if config.locked_profile_fields[field_name] then
18 return true
19 end
21 return false
22 end

Impressum / About Us