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

on delete, validate that actionhash is a link create #85

Open
harlantwood opened this issue May 21, 2023 · 0 comments · May be fixed by #84
Open

on delete, validate that actionhash is a link create #85

harlantwood opened this issue May 21, 2023 · 0 comments · May be fixed by #84
Assignees

Comments

@harlantwood
Copy link
Member

holochain core does not seem to do this.

something like this (from mewsfeed)

        FlatOp::StoreRecord(store_record) => match store_record {
            OpRecord::DeleteLink {
                original_action_hash,
                base_address,
                action,
            } => {
                let record = must_get_valid_record(original_action_hash)?;
                let create_link = match record.action() {
                    Action::CreateLink(create_link) => create_link.clone(),
                    _ => {
                        return Ok(ValidateCallbackResult::Invalid(
                            "The action that a DeleteLink deletes must be a CreateLink".to_string(),
                        ));
                    }
                };
...
@dauphin3 dauphin3 linked a pull request Jun 2, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants