[audit] Handle errors when fetching storage keys from Unstablebackend (#1440)

* Handle errors when fetching storage keys from Unstablebackend

* cargo fmt
This commit is contained in:
James Wilson authored and GitHub committed 2024-02-23 14:28:08 +01:00
1 parent 4614ff7bbb
commit 6f63ded5c1
1 file changed
+5
@@ -150,6 +150,11 @@ impl<T: Config> Stream for StorageItems<T> {
self.buffered_responses = items.items;
continue;
}
FollowEvent::OperationError(err) if err.operation_id == *self.operation_id => {
// Something went wrong obtaining storage items; mark as done and return the error.
self.done = true;
return Poll::Ready(Some(Err(Error::Other(err.error))));
}
_ => {
// We don't care about this event; wait for the next.
continue;