Skip to main content

remove_ctx

No overview available.

def remove_ctx(
f: F
) - > F

Removes the application context from the arguments of a wrapped function if it is present. This is used to adapt functions that might receive an AppContext as their first argument to a signature that does not expect it.

Parameters

NameTypeDescription
fFThe function to wrap, which may or may not expect an AppContext as its first argument.

Returns

TypeDescription
FThe wrapped function with the context removal logic.