X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=scpubgit%2FObject-Remote.git;a=blobdiff_plain;f=lib%2FObject%2FRemote%2FFuture.pm;h=966532f1094f132c2075b72923e133f9c64237f1;hp=83aad963a4f4eab9b24cc5273c86170a213ffd14;hb=bc06e92182c47337510900a0077079176200bfc0;hpb=668343cde7e6339cca56c66a41defdd28327f224 diff --git a/lib/Object/Remote/Future.pm b/lib/Object/Remote/Future.pm index 83aad96..966532f 100644 --- a/lib/Object/Remote/Future.pm +++ b/lib/Object/Remote/Future.pm @@ -99,8 +99,8 @@ sub AUTOLOAD { my $invocant = shift; my ($method) = our $AUTOLOAD =~ /^then::(.+)$/; my @args = @_; - return $invocant->and_then(sub { - my ($obj) = $_[0]->get; + return $invocant->then(sub { + my ($obj) = @_; return $obj->${\"start::${method}"}(@args); }); }