diff options
| author | Serguey Parkhomovsky <xindigo@gmail.com> | 2026-03-21 16:54:21 -0700 |
|---|---|---|
| committer | Serguey Parkhomovsky <xindigo@gmail.com> | 2026-03-21 16:54:21 -0700 |
| commit | 1ba272e2da4081ac108a9c442463fadd1da656f1 (patch) | |
| tree | a137d3b5bf36ee9f03d1db9bcc675d9d63958a9e /src/main.rs | |
| parent | 3f7821beada6cd80b24905abaf2c263df321f846 (diff) | |
Sort the output
Diffstat (limited to 'src/main.rs')
| -rw-r--r-- | src/main.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main.rs b/src/main.rs index b6d8006..36fea1f 100644 --- a/src/main.rs +++ b/src/main.rs @@ -4,7 +4,7 @@ use native_tls::TlsConnector; use printstats::*; use reqwest::Client; use rumqttc::{AsyncClient, Event, MqttOptions, Packet, QoS, Transport}; -use std::collections::HashMap; +use std::collections::{BTreeMap, HashMap}; use std::fs; use std::process; use std::sync::{Arc, RwLock}; @@ -211,7 +211,7 @@ async fn poll_bambu( } } -async fn root(State(state): State<StateMap>) -> Json<HashMap<String, PrinterState>> { +async fn root(State(state): State<StateMap>) -> Json<BTreeMap<String, PrinterState>> { Json( state .iter() |
