Skip to content

Commit d84ef05

Browse files
committed
remove unstable features and pin rust version
1 parent e4c72a6 commit d84ef05

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

rust-toolchain.toml

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[toolchain]
2+
channel = "1.65.0"

tinydancer/src/main.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@
2424
//!
2525
//! }
2626
//! })
27-
#![feature(async_closure)]
27+
// #![feature(async_closure)]
2828
#![allow(unused_imports)]
2929
#![allow(dead_code)]
30-
#![feature(mutex_unlock)]
30+
// #![feature(mutex_unlock)]
3131
mod tinydancer;
3232
use crossterm::style::Stylize;
3333
use reqwest::header::{ACCEPT, CONTENT_TYPE};

tinydancer/src/ui/ui.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ use std::sync::{Arc, Mutex};
1212
use std::thread::sleep;
1313
use std::time::Duration;
1414
use std::{any::Any, thread::Thread};
15-
use std::{fmt, thread::JoinHandle};
15+
use std::{fmt, mem::drop, thread::JoinHandle};
1616
use thiserror::Error;
1717
use tiny_logger::logs::info;
1818
use tui::layout::Rect;
@@ -245,7 +245,7 @@ impl ClientService<UiConfig> for UiService {
245245
}
246246
_ => {}
247247
}
248-
Mutex::unlock(status);
248+
drop(status);
249249
enable_raw_mode();
250250
if crossterm::event::poll(Duration::from_millis(100)).unwrap() {
251251
let ev = crossterm::event::read().unwrap();
@@ -262,7 +262,7 @@ impl ClientService<UiConfig> for UiService {
262262
*status = ClientStatus::ShuttingDown(String::from(
263263
"Shutting Down Gracefully...",
264264
));
265-
Mutex::unlock(status);
265+
drop(status);
266266
disable_raw_mode();
267267
}
268268
}

0 commit comments

Comments
 (0)