From: Matt S Trout Date: Thu, 17 Mar 2016 18:46:46 +0000 (+0000) Subject: only traverse keys given unset and lock selected value X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c35c4f369a961a13e5fa2fa8b76511ed894171bf;p=scpubgit%2FDX.git only traverse keys given unset and lock selected value --- diff --git a/lib/DX/Predicate/MemberAt.pm b/lib/DX/Predicate/MemberAt.pm index b3120a2..638ef19 100644 --- a/lib/DX/Predicate/MemberAt.pm +++ b/lib/DX/Predicate/MemberAt.pm @@ -2,6 +2,7 @@ package DX::Predicate::MemberAt; use DX::Utils qw(step INDICES_OF EXISTENCE_OF CONTENTS_OF string); use DX::ActionBuilder::ProxySetToAdd; +use DX::ActionBuilder::Null; use DX::Class; with 'DX::Role::Predicate'; @@ -64,9 +65,15 @@ sub _possible_resolution_list { } : () ), - ($key->can_set_value + (!$key->is_set + && $key->action_builder->isa('DX::ActionBuilder::UnsetValue') ? map { - my $set_key = $key->action_for_set_value(string(my $kstr = $_)); + my $set_key = DX::Action::SetValue->new( + target_path => $key->action_builder->target_path, + new_value => DX::ActionBuilder::Null->new( + target_path => $key->action_builder->target_path, + )->apply_to_value(string(my $kstr = $_)) + ); map $_->but_first($set_key) ->but_with_dependencies_on( [ undef ,=>