From 99306a4dab4919c1c9fed338560f8c3e01a6382f Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Tue, 11 Sep 2018 19:05:33 -0700 Subject: more subtle local ident check in release.db_expand() --- rust/src/api_entity_crud.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/rust/src/api_entity_crud.rs b/rust/src/api_entity_crud.rs index 1cb9adf8..461e1c7f 100644 --- a/rust/src/api_entity_crud.rs +++ b/rust/src/api_entity_crud.rs @@ -685,11 +685,11 @@ impl EntityCrud for ReleaseEntity { generic_db_insert_rev!(); fn db_expand(&mut self, conn: &DbConn, expand: ExpandFlags) -> Result<()> { - let ident = match &self.ident { - None => bail!("Can't expand a non-concrete entity"), - Some(s) => FatCatId::from_str(&s)?, - }; if expand.files { + let ident = match &self.ident { + None => bail!("Can't expand files on a non-concrete entity"), + Some(s) => FatCatId::from_str(&s)?, + }; self.files = Some(get_release_files(ident, conn)?); } if expand.container { -- cgit v1.2.3