switchover to rspace next_step and dump step()
[scpubgit/DX.git] / lib / DX / Role / Predicate.pm
index e2e76d6..a8e86a6 100644 (file)
@@ -1,17 +1,12 @@
 package DX::Role::Predicate;
 
-use List::Util qw(reduce);
-use DX::Utils qw(step CONTENTS_OF);
 use DX::Role;
 
 sub resolution_step_for {
   my ($self, $prop, @args) = @_;
-  my $rspace = $self->_resolution_space_for(@args);
-  return undef unless @{$rspace->members};
-  return step(
-    resolves => $prop,
-    resolution_space => $rspace
-  );
+  $self->_resolution_space_for(@args)
+       ->but(proposition => $prop)
+       ->next_step;
 }
 
 1;