diff --git a/crates/fj-interop/src/status_report.rs b/crates/fj-interop/src/status_report.rs index 7478fede1..a50b89111 100644 --- a/crates/fj-interop/src/status_report.rs +++ b/crates/fj-interop/src/status_report.rs @@ -2,25 +2,28 @@ /// Struct to store and update status messages pub struct StatusReport { - status: String, + status: Vec, } impl StatusReport { /// Create a new ``StatusReport`` instance with a blank status pub fn new() -> Self { - Self { - status: String::new(), - } + Self { status: Vec::new() } } /// Update the status pub fn update_status(&mut self, status: &str) { - self.status = status.to_string(); + self.status.push(status.to_string()); } /// Get current status - pub fn status(&self) -> &str { - self.status.as_str() + pub fn status(&self) -> String { + self.status.join("\n") + } + + /// Reset status + pub fn clear_status(&mut self) { + self.status.clear(); } }