fix version update route perf (#923)

* fix version update route perf

* fix tests
This commit is contained in:
Geometrically
2024-06-12 09:58:01 -07:00
committed by GitHub
parent b933202694
commit 872ffa02ce
8 changed files with 38 additions and 58 deletions

View File

@@ -362,7 +362,7 @@ impl AutomatedModerationQueue {
for file in
files.iter().filter(|x| x.version_id == version.id.into())
{
if let Some(hash) = file.hashes.get(&"sha1".to_string()) {
if let Some(hash) = file.hashes.get("sha1") {
if let Some((index, (sha1, _, file_name, _))) = hashes
.iter()
.enumerate()