Skip to content

Commit 2a5a25b

Browse files
committed
fix: Formatting and linting errors
1 parent 12f51f7 commit 2a5a25b

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

samples/identity/functions/main.py

+2
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ def beforeusersignedin(
4242

4343

4444
@identity_fn.before_email_sent()
45+
# pylint: disable=useless-return
4546
def beforeemailsent(
4647
event: identity_fn.AuthBlockingEvent
4748
) -> identity_fn.BeforeEmailSentResponse | None:
@@ -50,6 +51,7 @@ def beforeemailsent(
5051

5152

5253
@identity_fn.before_sms_sent()
54+
# pylint: disable=useless-return
5355
def beforesmssent(event: identity_fn.AuthBlockingEvent) -> identity_fn.BeforeSmsSentResponse | None:
5456
print(event)
5557
return None

src/firebase_functions/options.py

+7-5
Original file line numberDiff line numberDiff line change
@@ -987,12 +987,14 @@ def _endpoint(
987987

988988
if kwargs["event_type"] == event_type_before_create or kwargs[
989989
"event_type"] == event_type_before_sign_in:
990+
options = _typing.cast(BlockingOptions, self)
990991
blocking_trigger_options = _manifest.BlockingTriggerOptions(
991-
idToken=self.id_token if self.id_token is not None else False,
992-
accessToken=self.access_token
993-
if self.access_token is not None else False,
994-
refreshToken=self.refresh_token
995-
if self.refresh_token is not None else False,
992+
idToken=options.id_token
993+
if options.id_token is not None else False,
994+
accessToken=options.access_token
995+
if options.access_token is not None else False,
996+
refreshToken=options.refresh_token
997+
if options.refresh_token is not None else False,
996998
)
997999
else:
9981000
blocking_trigger_options = _manifest.BlockingTriggerOptions()

0 commit comments

Comments
 (0)