rename channel to threaded_archiver
I think that reflects its purpose much better
This commit is contained in:
parent
90e834722c
commit
9c6ff4eddf
3 changed files with 3 additions and 3 deletions
|
@ -1,4 +1,4 @@
|
||||||
mod channel;
|
mod threaded_archiver;
|
||||||
mod web;
|
mod web;
|
||||||
|
|
||||||
fn main() -> std::io::Result<()> {
|
fn main() -> std::io::Result<()> {
|
||||||
|
|
|
@ -5,7 +5,7 @@ use futures::Stream;
|
||||||
use percent_encoding::{utf8_percent_encode, NON_ALPHANUMERIC};
|
use percent_encoding::{utf8_percent_encode, NON_ALPHANUMERIC};
|
||||||
use v_htmlescape::escape as escape_html_entity;
|
use v_htmlescape::escape as escape_html_entity;
|
||||||
|
|
||||||
use crate::channel;
|
use crate::threaded_archiver;
|
||||||
|
|
||||||
use std::fmt::Write;
|
use std::fmt::Write;
|
||||||
use std::path::PathBuf;
|
use std::path::PathBuf;
|
||||||
|
@ -100,7 +100,7 @@ fn handle_tar(req: HttpRequest) -> impl Responder {
|
||||||
return Err(error::ErrorBadRequest("not a directory"));
|
return Err(error::ErrorBadRequest("not a directory"));
|
||||||
}
|
}
|
||||||
|
|
||||||
let stream = channel::stream_tar_in_thread(fullpath);
|
let stream = threaded_archiver::stream_tar_in_thread(fullpath);
|
||||||
let resp = HttpResponse::Ok()
|
let resp = HttpResponse::Ok()
|
||||||
.content_type("application/x-tar")
|
.content_type("application/x-tar")
|
||||||
.streaming(stream.map_err(|_e| error::ErrorBadRequest("stream error")));
|
.streaming(stream.map_err(|_e| error::ErrorBadRequest("stream error")));
|
||||||
|
|
Loading…
Add table
Reference in a new issue