The-Commit-Company / raven

Simple, open source team messaging platform
https://thecommit.company/products/raven
GNU Affero General Public License v3.0
296 stars 120 forks source link

Notifications are shown for messages sent by the sender in channels #813

Open nikkothari22 opened 6 months ago

nikkothari22 commented 6 months ago

Service worker doesn't have access to any variables or local storage.

  1. Store the current user in IndexedDB
  2. Service worker fetches current user ID from indexedDB to check whether to show a notification
  3. Clear current user from indexedDB after logging out.

This needs to be done before implementing push notifications on web app to avoid notification hell.

linear[bot] commented 6 months ago

RAV-156 Notifications are shown for messages sent by the sender in channels