fix: channel blockage caused by fuse permissions under the root user (#321)

This commit is contained in:
三咲雅 · Misaki Masa 2023-10-26 00:20:32 +08:00 committed by GitHub
parent 24fd587431
commit 5c3c100d5d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -52,8 +52,10 @@ impl Files {
while let Ok(Some(item)) = it.next_entry().await {
select! {
_ = tx.closed() => break,
Ok(meta) = item.metadata() => {
tx.send(File::from_meta(Url::from(item.path()), meta).await).ok();
result = item.metadata() => {
if let Ok(meta) = result {
tx.send(File::from_meta(Url::from(item.path()), meta).await).ok();
}
}
}
}