hemanthrajv / flutter_compass

MIT License
102 stars 188 forks source link

Fix bug: allow multiple listeners to compass stream. #59

Closed gabeschine closed 3 years ago

gabeschine commented 3 years ago

recieveBroadcastStream() is a broadcast stream, but that breaks if you create it every time someone asks for the stream to listen to.

This change caches the stream itself in a static member variable and vends it when requested.