mirror of
https://github.com/nushell/nushell.git
synced 2024-12-23 15:39:06 +01:00
add support for the text/csv content-type (#2587)
This commit is contained in:
parent
b133724b38
commit
8388afc9d9
@ -190,6 +190,15 @@ async fn helper(
|
|||||||
)
|
)
|
||||||
.into_value(tag),
|
.into_value(tag),
|
||||||
)),
|
)),
|
||||||
|
(mime::TEXT, mime::CSV) => Ok((
|
||||||
|
Some("csv".to_string()),
|
||||||
|
UntaggedValue::string(
|
||||||
|
r.body_string()
|
||||||
|
.await
|
||||||
|
.map_err(|e| generate_error("text", e, &span))?,
|
||||||
|
)
|
||||||
|
.into_value(tag),
|
||||||
|
)),
|
||||||
(mime::TEXT, mime::PLAIN) => {
|
(mime::TEXT, mime::PLAIN) => {
|
||||||
let path_extension = url::Url::parse(location)
|
let path_extension = url::Url::parse(location)
|
||||||
.map_err(|_| {
|
.map_err(|_| {
|
||||||
|
Loading…
Reference in New Issue
Block a user