sources/ldap: add list_flatten function to property mappings, enable on managed LDAP mappings
closes #2199 Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
@ -18,6 +18,17 @@ Example:
|
||||
user_email_local = regex_replace(request.user.email, '(.+)@.+', '')
|
||||
```
|
||||
|
||||
### `list_flatten(value: list[Any] | Any) -> Optional[Any}`
|
||||
|
||||
Flatten a list by either returning its first element, None if the list is empty, or the passed in object if its not a list.
|
||||
|
||||
Example:
|
||||
|
||||
```python
|
||||
user = list_flatten(["foo"])
|
||||
# user = "foo"
|
||||
```
|
||||
|
||||
### `ak_is_group_member(user: User, **group_filters) -> bool`
|
||||
|
||||
Check if `user` is member of a group matching `**group_filters`.
|
||||
|
||||
Reference in New Issue
Block a user