get_max_age
Return the max-age from the response Cache-Control header as an integer, or None if it wasn't found or wasn't an integer.
def get_max_age(
response: HttpResponse
) - > int | None
Return the max-age from the response Cache-Control header as an integer, or None if it wasn't found or wasn't an integer.
Parameters
| Name | Type | Description |
|---|---|---|
| response | HttpResponse | The response object containing headers to be parsed for cache directives |
Returns
| Type | Description |
|---|---|
| `int | None` |