Skip to content

Commit 2791503

Browse files
dumbbellthe-mikedavis
authored andcommitted
rabbit_khepri: Adapt delete_or_fail/1 to Khepri 0.17.0
If the tree node to delete does not exist, the node props map is empty.
1 parent c3319a1 commit 2791503

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

deps/rabbit/src/rabbit_khepri.erl

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1036,7 +1036,9 @@ delete_or_fail(Path) ->
10361036
0 -> {error, {node_not_found, #{}}};
10371037
_ -> ok
10381038
end;
1039-
Error ->
1039+
{ok, #{} = NodePropsMap} when NodePropsMap =:= #{} ->
1040+
{error, {node_not_found, #{}}};
1041+
{error, _} = Error ->
10401042
Error
10411043
end.
10421044

0 commit comments

Comments
 (0)