mirror of https://github.com/fafhrd91/actix-web
accept suggestion for actix-files/src/named.rs
Co-authored-by: Yuki Okushi <jtitor@2k36.org>
This commit is contained in:
parent
9e94de0d72
commit
85b8b1f0af
|
@ -132,8 +132,7 @@ impl NamedFile {
|
||||||
mime::IMAGE | mime::TEXT | mime::AUDIO | mime::VIDEO => DispositionType::Inline,
|
mime::IMAGE | mime::TEXT | mime::AUDIO | mime::VIDEO => DispositionType::Inline,
|
||||||
mime::APPLICATION => match ct.subtype() {
|
mime::APPLICATION => match ct.subtype() {
|
||||||
mime::JAVASCRIPT | mime::JSON => DispositionType::Inline,
|
mime::JAVASCRIPT | mime::JSON => DispositionType::Inline,
|
||||||
name if name == "wasm" => DispositionType::Inline,
|
name if name == "wasm" || name == "xhtml" => DispositionType::Inline,
|
||||||
name if name == "xhtml" => DispositionType::Inline,
|
|
||||||
_ => DispositionType::Attachment,
|
_ => DispositionType::Attachment,
|
||||||
},
|
},
|
||||||
_ => DispositionType::Attachment,
|
_ => DispositionType::Attachment,
|
||||||
|
|
Loading…
Reference in New Issue