Skip to content

Check Del command in all families #5316

@BagritsevichStepan

Description

@BagritsevichStepan

We have a bad pattern in our codebase like this:

auto it = db_slice.FindMutable(op_args.db_cntx, key).it;  // post_updater will run immediately
if (IsValid(it)) {
   db_slice.Del(op_args.db_cntx, it);

This can lead to bugs, because in such cases we don't provide the expected object type to the FindMutable call, which means we can remove an object of a different type from the database. We should verify that everything works as expected in all such cases — and it's better to avoid this pattern altogether.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions