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.
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
calledcheckObserve
that checks for the observe flag upon receiving the first response. This approach eliminates the need for await, ensuring that theCoapObserveClientRelation
object already has ouronData
method when the first response is received.