Conversation

russellwheatley

Description

  1. app check web onTokenChanged was broken. The stream was never listened (it was just mapped) to which was changed here to listen().
  2. Properly cleaned up and initialised streams made on this commit.
  3. Cleaned up streams on "hot restart" on this commit.
  4. Also reinserted the debug token for web on example app that was removed in the recent web folder clean up.

Related Issues

related to: #7064

Checklist

Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes ([x]).
This will ensure a smooth and quick review process. Updating the pubspec.yaml and changelogs is not required.

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • My PR includes unit or integration tests for all changed/updated/fixed behaviors (See Contributor Guide).
  • All existing and new tests are passing.
  • I updated/added relevant documentation (doc comments with ///).
  • The analyzer (melos run analyze) does not report any problems on my PR.
  • I read and followed the Flutter Style Guide.
  • I signed the CLA.
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

Does your PR require plugin users to manually update their apps to accommodate your change?

  • Yes, this is a breaking change.
  • No, this is not a breaking change.

@russellwheatleyrussellwheatley changed the title fix(app-check, web): fixed broken onTokenChanged and ensured it is properly cleaned up. Also clean up on "hot restart" fix(app-check, web): fixed broken onTokenChanged and ensured it is properly cleaned up. Streams are also cleaned up on "hot restart" Jun 10, 2024
@@ -33,6 +33,9 @@
<link rel="manifest" href="manifest.json">
</head>
<body>
<script>
self.FIREBASE_APPCHECK_DEBUG_TOKEN = true;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it supposed to stay?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, just allows us to use debug token to test when we run the example app 👍

@LyokoneLyokone merged commit 093b5fe into master Jun 11, 2024
25 checks passed
@LyokoneLyokone deleted the app-check-7064 branch June 11, 2024 13:26
@firebasefirebase locked and limited conversation to collaborators Jul 12, 2024
Sign up for free to subscribe to this conversation on . Already have an account? Sign in.
None yet
None yet

Successfully merging this pull request may close these issues.