mirror of
https://github.com/sxyazi/yazi.git
synced 2026-05-13 08:16:40 +00:00
fix!: open command doesn't work under empty directories (#3226)
This commit is contained in:
parent
d8b0425a10
commit
149a5feffb
45 changed files with 277 additions and 280 deletions
|
|
@ -33,7 +33,7 @@ impl From<Error> for std::io::Error {
|
|||
Error::IO(e) => e,
|
||||
Error::Serde(e) => Self::new(std::io::ErrorKind::InvalidData, e),
|
||||
Error::Status(status) => match status.code {
|
||||
responses::StatusCode::Ok => Self::new(std::io::ErrorKind::Other, "unexpected OK"),
|
||||
responses::StatusCode::Ok => Self::other("unexpected OK"),
|
||||
responses::StatusCode::Eof => Self::from(std::io::ErrorKind::UnexpectedEof),
|
||||
responses::StatusCode::NoSuchFile => Self::from(std::io::ErrorKind::NotFound),
|
||||
responses::StatusCode::PermissionDenied => Self::from(std::io::ErrorKind::PermissionDenied),
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ impl Operator {
|
|||
status.into()
|
||||
}
|
||||
|
||||
pub async fn fsetstat<'a>(&self, handle: &str, attrs: &'a Attrs) -> Result<(), Error> {
|
||||
pub async fn fsetstat(&self, handle: &str, attrs: &Attrs) -> Result<(), Error> {
|
||||
let status: responses::Status = self.send(requests::FSetStat::new(handle, attrs)).await?;
|
||||
status.into()
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue