mirror of
https://github.com/rojo-rbx/rojo.git
synced 2026-04-28 08:36:11 +00:00
Move web server onto main thread
This commit is contained in:
@@ -196,13 +196,9 @@ fn main() {
|
||||
});
|
||||
}
|
||||
|
||||
web::start(config.clone(), project.clone(), vfs.clone());
|
||||
|
||||
println!("Server listening on port {}", port);
|
||||
|
||||
loop {
|
||||
thread::park();
|
||||
}
|
||||
web::start(config.clone(), project.clone(), vfs.clone());
|
||||
},
|
||||
("pack", _) => {
|
||||
eprintln!("'rojo pack' is not yet implemented!");
|
||||
|
||||
@@ -109,7 +109,6 @@ pub fn start(config: Config, project: Project, vfs: Arc<Mutex<Vfs>>) {
|
||||
])));
|
||||
}
|
||||
|
||||
thread::spawn(move || {
|
||||
rouille::start_server(address, move |request| {
|
||||
router!(request,
|
||||
(GET) (/) => {
|
||||
@@ -189,5 +188,4 @@ pub fn start(config: Config, project: Project, vfs: Arc<Mutex<Vfs>>) {
|
||||
_ => rouille::Response::empty_404()
|
||||
)
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user