shamblett / coap

A Coap package for dart
Other
16 stars 13 forks source link

Fix: first observe response not being handled #195

Closed jorgesanfz closed 2 weeks ago

jorgesanfz commented 3 weeks ago

PR related to issue #193

To prevent the check from blocking the function until after the first response is received, I created a method within the CoapObserveClientRelation called checkObserve that checks for the observe flag upon receiving the first response. This approach eliminates the need for await, ensuring that the CoapObserveClientRelation object already has our onData method when the first response is received.

shamblett commented 2 weeks ago

OK thanks, seems to work OK, merged, will be in the next release.

Note don't worry about the PR failing on windows, this is known and being worked on.