Skip to content

Commit

Permalink
fix: heads return the list of missing assets
Browse files Browse the repository at this point in the history
  • Loading branch information
theus77 committed Oct 12, 2024
1 parent e39eec3 commit 82b2c99
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public function head(string $hash): bool

public function heads(string ...$hashes): array
{
return \array_filter($hashes, fn (string $hash) => $this->head($hash));
return \array_filter($hashes, fn (string $hash) => !$this->head($hash));
}

public function create(string $hash, string $filename): bool
Expand Down
2 changes: 1 addition & 1 deletion EMS/common-bundle/src/Storage/Service/EntityStorage.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public function head(string $hash): bool

public function heads(string ...$hashes): array
{
return \array_filter($hashes, fn (string $hash) => $this->head($hash));
return \array_filter($hashes, fn (string $hash) => !$this->head($hash));
}

public function getSize(string $hash): int
Expand Down

0 comments on commit 82b2c99

Please sign in to comment.