File tree Expand file tree Collapse file tree 2 files changed +8
-0
lines changed
test/electric/shape_cache Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -153,6 +153,13 @@ defmodule Electric.ShapeCache.ShapeStatus do
153153 def unlink_handle_from_shape ( stack_ref , shape_handle ) do
154154 stack_id = extract_stack_id ( stack_ref )
155155 shape = ShapeDb . unlink_handle_from_shape! ( stack_id , shape_handle )
156+
157+ :ets . update_element (
158+ shape_meta_table ( stack_ref ) ,
159+ shape_handle ,
160+ { @ shape_meta_shape_hash_pos , nil }
161+ )
162+
156163 { :ok , shape }
157164 rescue
158165 ArgumentError ->
Original file line number Diff line number Diff line change @@ -114,6 +114,7 @@ defmodule Electric.ShapeCache.ShapeStatusTest do
114114
115115 # After unlinking, the shape should not be findable via get_existing_shape
116116 refute ShapeStatus . get_existing_shape ( state , shape )
117+ refute ShapeStatus . has_shape_handle? ( state , shape_handle )
117118
118119 # But the shape should still be fetchable by handle (metadata still exists)
119120 assert { :ok , ^ shape } = ShapeStatus . fetch_shape_by_handle ( state , shape_handle )
You can’t perform that action at this time.
0 commit comments