Skip to content

Commit

Permalink
fix: stop recording when no listeners
Browse files Browse the repository at this point in the history
  • Loading branch information
hannojg committed Jun 18, 2024
1 parent 593c189 commit a073a4d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion package/cpp/RNFFilamentRecorder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ std::shared_ptr<Listener> FilamentRecorder::addOnReadyForMoreDataListener(ReadyF

bool FilamentRecorder::onReadyForMoreData() {
// notify all JS listeners
bool shouldContinueNext = true;
bool shouldContinueNext = _listenerManager->getHasListeners();
_listenerManager->forEach([&shouldContinueNext](const ReadyForMoreDataCallback& callback) {
bool result = callback();
if (!result) {
Expand Down

0 comments on commit a073a4d

Please sign in to comment.