0f56d00959
* added example for custom user attributes * simplified example Co-authored-by: croudsarabi <constantin.roudsarabi@andrena.de>
9 lines
250 B
Markdown
9 lines
250 B
Markdown
- `user`: The current user. This may be `None` if there is no contextual user. See ([User](../user-group/user.md#object-attributes))
|
|
|
|
Example:
|
|
|
|
```python
|
|
return {
|
|
"custom_attribute": request.user.attributes.get("custom_attribute", "default"),
|
|
}
|
|
``` |