Context::Simple::inject_if_block returns true value on block
[p5sagit/Devel-Declare.git] / lib / Devel / Declare / Context / Simple.pm
index afbcaf4..52dd70d 100644 (file)
@@ -131,7 +131,9 @@ sub inject_if_block {
     substr($linestr, $self->offset + 1, 0) = $inject;
     substr($linestr, $self->offset, 0) = $before;
     $self->set_linestr($linestr);
+    return 1;
   }
+  return 0;
 }
 
 sub scope_injector_call {