Skip to content
This repository has been archived by the owner on Oct 23, 2022. It is now read-only.

Commit

Permalink
Rustfmt
Browse files Browse the repository at this point in the history
  • Loading branch information
c410-f3r committed Jul 31, 2020
1 parent 8668c68 commit c0b8743
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions unixfs/src/walk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -290,20 +290,20 @@ impl Walker {
UnixFsType::Raw | UnixFsType::File => {
let (bytes, file_size, metadata, step) =
IdleFileVisit::default().start_from_parsed(flat, cache)?;
let (cid, name, depth) = next.expect("validated at new and earlier in this method");
let file_continues = step.is_some();
let ie = match current {
Some(mut ie) => {
ie.as_file(cid, &name, depth, metadata, step, file_size);
let (cid, name, depth) = next.expect("validated at new and earlier in this method");
let file_continues = step.is_some();

let ie = match current {
Some(mut ie) => {
ie.as_file(cid, &name, depth, metadata, step, file_size);
ie
}
_ => InnerEntry::new_root_file(cid, metadata, &name, step, file_size, depth),
};

let next = pending.pop();
let segment = FileSegment::first(bytes, !file_continues);

let state = if file_continues || next.is_some() {
State::Unfinished(Self {
current: Some(ie),
Expand Down

0 comments on commit c0b8743

Please sign in to comment.