You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
let current_open_message = self.get_current_open_message_for_signed_entity_type(&signed_entity_type)
188
187
.await
189
-
.with_context(|| format!("AggregatorRunner can not get current open message for signed entity type: '{}'",&signed_entity_type))?
190
-
{
191
-
if !open_message.is_certified && !open_message.is_expired{
192
-
returnOk(Some(open_message));
188
+
.with_context(|| format!("AggregatorRunner can not get current open message for signed entity type: '{}'",&signed_entity_type))?;
189
+
match current_open_message {
190
+
None => {
191
+
let protocol_message = self.compute_protocol_message(&signed_entity_type).await.with_context(|| format!("AggregatorRunner can not compute protocol message for signed_entity_type: '{signed_entity_type}'"))?;
192
+
let open_message_new = self.create_open_message(&signed_entity_type,&protocol_message)
193
+
.await
194
+
.with_context(|| format!("AggregatorRunner can not create open message for signed_entity_type: '{signed_entity_type}'"))?;
195
+
196
+
returnOk(Some(open_message_new));
197
+
}
198
+
Some(open_message) => {
199
+
if !open_message.is_certified && !open_message.is_expired{
200
+
returnOk(Some(open_message));
201
+
}
193
202
}
194
-
continue;
195
203
}
196
-
let protocol_message = self.compute_protocol_message(&signed_entity_type).await.with_context(|| format!("AggregatorRunner can not compute protocol message for signed_entity_type: '{signed_entity_type}'"))?;
197
-
let open_message_new = self.create_open_message(&signed_entity_type,&protocol_message)
198
-
.await
199
-
.with_context(|| format!("AggregatorRunner can not create open message for signed_entity_type: '{signed_entity_type}'"))?;
0 commit comments