Skip to content

Bad state: Stream has already been listened to #5

@HenriqueGuima

Description

@HenriqueGuima

It seems the code runs through this block a second time for some reason which gives me the Bad State Error. Is there a way to fix this?

_receivedDataStream =
                flutterReactiveBle.subscribeToCharacteristic(_txCharacteristic);
            _receivedDataStream.listen((data) {
              onNewReceivedData(data);
            }, onError: (dynamic error) {
              _logTexts = "${_logTexts}Error:$error$id\n";
            });

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions