Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: bug while scaffolding collection by author #290

Merged
merged 2 commits into from
May 20, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/scaffold/collection/coordinator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ fn add_delete_link_in_delete_function(
let zome_file_tree = ZomeFileTree::from_zome_manifest(dna_file_tree, chosen_coordinator_zome)?;

let snake_case_entry_type = entry_type_reference.entry_type.to_case(Case::Snake);
let pascal_case_entry_type = entry_type_reference.entry_type.to_case(Case::Pascal);

let target_hash_variable = match entry_type_reference.reference_entry_hash {
true =>
Expand Down Expand Up @@ -245,7 +246,7 @@ fn add_delete_link_in_delete_function(
);
delete_link_stmts.insert(0, format!(r#"
let details = get_details(original_{snake_case_entry_type}_hash.clone(), GetOptions::default())?
.ok_or(wasm_error!(WasmErrorInner::Guest(String::from("{{pascal_entry_def_name}} not found"))))?;
.ok_or(wasm_error!(WasmErrorInner::Guest(String::from("{pascal_entry_def_name} not found"))))?;
"#));
delete_link_stmts.push(format!(
r#"let links = get_links(
Expand Down
Loading