dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
11c67c2
)
consistent incr() return value in case of error. follow up 74579
author
Antoine Musso
<hashar@users.mediawiki.org>
Thu, 25 Nov 2010 19:47:24 +0000
(19:47 +0000)
committer
Antoine Musso
<hashar@users.mediawiki.org>
Thu, 25 Nov 2010 19:47:24 +0000
(19:47 +0000)
includes/BagOStuff.php
patch
|
blob
|
history
diff --git
a/includes/BagOStuff.php
b/includes/BagOStuff.php
index
04900f4
..
5ef9472
100644
(file)
--- a/
includes/BagOStuff.php
+++ b/
includes/BagOStuff.php
@@
-130,9
+130,12
@@
abstract class BagOStuff {
}
}
+ /**
+ * @return null if lock is not possible. New value incremented by 1
+ */
public function incr( $key, $value = 1 ) {
if ( !$this->lock( $key ) ) {
- return
false
;
+ return
null
;
}
$value = intval( $value );