diff --git a/src/scheduled_tasks.rs b/src/scheduled_tasks.rs index 52962877f..497e367b0 100644 --- a/src/scheduled_tasks.rs +++ b/src/scheduled_tasks.rs @@ -579,13 +579,13 @@ async fn build_update_instance_form( // This is the only kind of error that means the instance is dead return None; }; + let status = res.status(); + if status.is_client_error() || status.is_server_error() { + return None; + } // In this block, returning `None` is ignored, and only means not writing nodeinfo to db async { - if res.status().is_client_error() { - return None; - } - let node_info_url = res .json::() .await @@ -617,6 +617,7 @@ async fn build_update_instance_form( } .await; + dbg!("reach here?"); Some(instance_form) }