mirror of
https://github.com/redlib-org/redlib.git
synced 2025-06-05 22:30:17 +00:00
Fix clippy warnings
This commit is contained in:
parent
b0f985c687
commit
c5d11f220e
5 changed files with 24 additions and 35 deletions
|
@ -21,7 +21,7 @@ pub(crate) static INSTANCE_INFO: Lazy<InstanceInfo> = Lazy::new(InstanceInfo::ne
|
|||
pub async fn instance_info(req: Request<Body>) -> Result<Response<Body>, String> {
|
||||
// This will retrieve the extension given, or create a new string - which will
|
||||
// simply become the last option, an HTML page.
|
||||
let extension = req.param("extension").unwrap_or(String::new());
|
||||
let extension = req.param("extension").unwrap_or_default();
|
||||
let response = match extension.as_str() {
|
||||
"yaml" | "yml" => info_yaml(),
|
||||
"txt" => info_txt(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue