Skip to content
Snippets Groups Projects

Write `get-file` and commands to get the list of blocks from another node

Merged DISSOUBRAY Nathan requested to merge request_block_list into master
15 files
+ 1185
822
Compare changes
  • Side-by-side
  • Inline
Files
15
+ 4
7
use futures::channel::mpsc::Sender;
use tokio::sync::Mutex;
use tokio::sync::mpsc::UnboundedSender;
use crate::commands::DragoonCommand;
pub(crate) struct AppState {
pub sender: Mutex<Sender<DragoonCommand>>,
pub cmd_sender: UnboundedSender<DragoonCommand>,
}
impl AppState {
pub fn new(sender: Sender<DragoonCommand>) -> Self {
AppState {
sender: Mutex::new(sender),
}
pub fn new(cmd_sender: UnboundedSender<DragoonCommand>) -> Self {
AppState { cmd_sender }
}
}
Loading