Skip to content

docs(flutter,android): keep the push subscription open in README samples - #2099

Merged
ChiragAgg5k merged 1 commit into
mainfrom
docs/readme-review-fixes
Oct 17, 2026
Merged

ChiragAgg5k merged 1 commit into
mainfrom
docs/readme-review-fixes

Conversation

@ChiragAgg5k

@ChiragAgg5k ChiragAgg5k commented Oct 17, 2026 •

Copy link
Copy Markdown
Member

What does this PR do?

The Flutter and Android README Push samples call subscription.unsubscribe() right after subscribing, so copying them tears the subscription down before any message can arrive. The samples now keep the subscription, and a sentence says to unsubscribe when you stop listening (dispose() / onDestroy()).

Raised by Hansi on the README-only SDK PR appwrite/sdk-for-flutter#342.

Test Plan

  • php example.php flutter client and php example.php android client, then read the Push section of each generated README
  • Confirmed unsubscribe() exists on the generated Flutter and Android push subscriptions
  • composer lint-twig, composer refactor:check, ./.github/scripts/max-line-length.sh . 1200 "*.twig"

Related PRs and Issues

Closes #2101

@hansi-codes

hansi-codes Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

🟢 Tier S · Ready to merge

The documentation changes correctly preserve the subscription and give an appropriate cleanup point.

The Flutter and Android Push README samples now keep the returned subscription instead of immediately unsubscribing. Each README also explains when to unsubscribe as part of ending message handling.

Verdict New comments Fixed Still open
✅ Approved 0 0 0
📂 Walkthrough · 2
File Change
templates/android/README.md.twig Keeps the Push subscription active and documents unsubscribing when the activity stops listening.
templates/flutter/README.md.twig Keeps the Push subscription active and documents unsubscribing when the widget stops listening.

Reviewed b4ea883 · Details · Comment @hansi-codes review to re-run, or mention @hansi-codes with a question.

@hansi-codes hansi-codes Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Tier S · Looks good to merge. Summary

@ChiragAgg5k ChiragAgg5k self-assigned this Oct 17, 2026
@ChiragAgg5k
ChiragAgg5k merged commit 73cf4df into main Oct 17, 2026
61 checks passed
@ChiragAgg5k
ChiragAgg5k deleted the docs/readme-review-fixes branch October 17, 2026 17:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Keep the push subscription open in the Flutter and Android README samples

1 participant