diff --git a/libs/jwst-storage/src/storage/blobs/blob_storage.rs b/libs/jwst-storage/src/storage/blobs/blob_storage.rs index d305e69e..726157bb 100644 --- a/libs/jwst-storage/src/storage/blobs/blob_storage.rs +++ b/libs/jwst-storage/src/storage/blobs/blob_storage.rs @@ -1,4 +1,5 @@ use jwst_core::{Base64Engine, URL_SAFE_ENGINE}; +use sea_orm::FromQueryResult; use sha2::{Digest, Sha256}; use super::*; @@ -40,10 +41,16 @@ impl BlobDBStorage { } async fn keys(&self, workspace: &str) -> Result, DbErr> { + #[derive(FromQueryResult)] + struct BlobHash { + hash: String, + } + Blobs::find() .filter(BlobColumn::WorkspaceId.eq(workspace)) .select_only() .column(BlobColumn::Hash) + .into_model::() .all(&self.pool) .await .map(|r| r.into_iter().map(|f| f.hash).collect())