refactor: use type enum in file stats for asar archive (#39889)
This commit is contained in:
parent
18f517d8a6
commit
d75a852743
5 changed files with 31 additions and 40 deletions
|
@ -311,14 +311,12 @@ bool Archive::Stat(const base::FilePath& path, Stats* stats) const {
|
|||
return false;
|
||||
|
||||
if (node->Find("link")) {
|
||||
stats->is_file = false;
|
||||
stats->is_link = true;
|
||||
stats->type = FileType::kLink;
|
||||
return true;
|
||||
}
|
||||
|
||||
if (node->Find("files")) {
|
||||
stats->is_file = false;
|
||||
stats->is_directory = true;
|
||||
stats->type = FileType::kDirectory;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue