Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/firebase_functions/firestore_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,6 @@ def _firestore_endpoint_handler(
event_namespace = event_attributes["namespace"]
event_document = event_attributes["document"]
event_database = event_attributes["database"]
event_auth_type = event_attributes["authtype"]
event_auth_id = event_attributes["authid"]

time = event_attributes["time"]
event_time = _util.timestamp_conversion(time)
Expand Down Expand Up @@ -208,6 +206,8 @@ def _firestore_endpoint_handler(
func = _core._with_init(func)

if event_type.endswith(".withAuthContext"):
event_auth_type = event_attributes["authtype"]
event_auth_id = event_attributes["authid"]
database_event_with_auth_context = AuthEvent(**vars(database_event),
auth_type=event_auth_type,
auth_id=event_auth_id)
Expand Down Expand Up @@ -270,7 +270,7 @@ def on_document_written_with_auth_context(**kwargs
) -> _typing.Callable[[_C1], _C1]:
"""
Event handler that triggers when a document is created, updated, or deleted in Firestore.
This trigger will also provide the authentication context of the principal who triggered
This trigger will also provide the authentication context of the principal who triggered
the event.

Example:
Expand Down Expand Up @@ -369,7 +369,7 @@ def on_document_updated_with_auth_context(**kwargs
) -> _typing.Callable[[_C1], _C1]:
"""
Event handler that triggers when a document is updated in Firestore.
This trigger will also provide the authentication context of the principal who triggered
This trigger will also provide the authentication context of the principal who triggered
the event.

Example:
Expand Down Expand Up @@ -468,7 +468,7 @@ def on_document_created_with_auth_context(**kwargs
) -> _typing.Callable[[_C2], _C2]:
"""
Event handler that triggers when a document is created in Firestore.
This trigger will also provide the authentication context of the principal who triggered
This trigger will also provide the authentication context of the principal who triggered
the event.

Example:
Expand Down Expand Up @@ -567,7 +567,7 @@ def on_document_deleted_with_auth_context(**kwargs
) -> _typing.Callable[[_C2], _C2]:
"""
Event handler that triggers when a document is deleted in Firestore.
This trigger will also provide the authentication context of the principal who triggered
This trigger will also provide the authentication context of the principal who triggered
the event.

Example:
Expand Down