summaryrefslogtreecommitdiffstats
path: root/rust/src/api_entity_crud.rs
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2018-12-24 16:04:13 -0800
committerBryan Newbold <bnewbold@robocracy.org>2018-12-24 16:04:13 -0800
commitb86e007b7469ebb22a806d38aca0bccf9078e80d (patch)
tree69dc8bda4316cae4bbdbe3acea287d46baa42b96 /rust/src/api_entity_crud.rs
parent86fd0a416efd4015dc47494e723afd7f13771006 (diff)
downloadfatcat-b86e007b7469ebb22a806d38aca0bccf9078e80d.tar.gz
fatcat-b86e007b7469ebb22a806d38aca0bccf9078e80d.zip
rust impl of API harmonization
Diffstat (limited to 'rust/src/api_entity_crud.rs')
-rw-r--r--rust/src/api_entity_crud.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/rust/src/api_entity_crud.rs b/rust/src/api_entity_crud.rs
index ee2d4ef3..b5e37412 100644
--- a/rust/src/api_entity_crud.rs
+++ b/rust/src/api_entity_crud.rs
@@ -829,7 +829,7 @@ impl EntityCrud for FileEntity {
size: None,
urls: None,
mimetype: None,
- releases: None,
+ release_ids: None,
state: Some(ident_row.state().unwrap().shortname()),
ident: Some(FatCatId::from_uuid(&ident_row.id).to_string()),
revision: ident_row.rev_id.map(|u| u.to_string()),
@@ -880,7 +880,7 @@ impl EntityCrud for FileEntity {
size: rev_row.size.map(|v| v as i64),
urls: Some(urls),
mimetype: rev_row.mimetype,
- releases: Some(releases.iter().map(|fcid| fcid.to_string()).collect()),
+ release_ids: Some(releases.iter().map(|fcid| fcid.to_string()).collect()),
state: state,
ident: ident_id,
revision: Some(rev_row.id.to_string()),
@@ -925,7 +925,7 @@ impl EntityCrud for FileEntity {
let mut file_url_rows: Vec<FileRevUrlNewRow> = vec![];
for (model, rev_id) in models.iter().zip(rev_ids.iter()) {
- match &model.releases {
+ match &model.release_ids {
None => (),
Some(release_list) => {
let these_release_rows: Result<Vec<FileReleaseRow>> = release_list