Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Turn _incrdecr into a method
The `$!active` and `$!readonly` variables are object attributes and thus
need `self` to be available so that they can be read.  Hence the sub should
be a method.
  • Loading branch information
Paul Cochrane committed May 21, 2015
1 parent 2104dc0 commit d62709a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Cache/Memcached.pm
Expand Up @@ -959,7 +959,7 @@ method decr ($key, $offset) {
$._incrdecr("incr", $key, $offset);
}

sub _incrdecr ($cmdname, $key, $value) {
method _incrdecr ($cmdname, $key, $value) {
return if ! $!active || $!readonly;

my $stime;
Expand Down

0 comments on commit d62709a

Please sign in to comment.