From 8ee11ac32cd3c7c4ccafd5d309681e079d5ba6f1 Mon Sep 17 00:00:00 2001 From: Mark Qvist Date: Thu, 29 Aug 2024 13:14:55 +0200 Subject: [PATCH] Added request concluded status to Link API --- RNS/Link.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/RNS/Link.py b/RNS/Link.py index e36e418..2bf9af4 100644 --- a/RNS/Link.py +++ b/RNS/Link.py @@ -1288,6 +1288,17 @@ class RequestReceipt(): else: return None + def concluded(self): + """ + :returns: True if the associated request has concluded (successfully or with a failure), otherwise False. + """ + if self.status == RequestReceipt.READY: + return True + elif self.status == RequestReceipt.FAILED: + return True + else: + return False + class RequestReceiptCallbacks: