Skip to content

Commit c516719

Browse files
committed
Merge pull request #20 from rickywiens/multi-fix
Fixing multi declaration. various fixes to documentation.
2 parents df0f0cc + 681c50a commit c516719

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/Redis.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ class Redis
5050
/**
5151
* Multi
5252
*/
53-
const MULTI = '';
54-
const PIPELINE = '';
53+
const MULTI = 0;
54+
const PIPELINE = 1;
5555

5656
/**
5757
* Type
@@ -253,7 +253,7 @@ public function delete( $key1, $key2 = null, $key3 = null ) {}
253253
/**
254254
* Enter and exit transactional mode.
255255
*
256-
* @internal param Redis::MULTI|Redis::PIPELINE
256+
* @param int Redis::MULTI|Redis::PIPELINE
257257
* Defaults to Redis::MULTI.
258258
* A Redis::MULTI block of commands runs as a single transaction;
259259
* a Redis::PIPELINE block is simply transmitted faster to the server, but without any guarantee of atomicity.
@@ -277,7 +277,7 @@ public function delete( $key1, $key2 = null, $key3 = null ) {}
277277
* // 3 => 'val2');
278278
* </pre>
279279
*/
280-
public function multi( ) {}
280+
public function multi( $mode = Redis::MULTI ) {}
281281

282282
/**
283283
* @see multi()
@@ -719,7 +719,6 @@ public function lLen( $key ) {}
719719
/**
720720
* @see lLen()
721721
* @param string $key
722-
* @param int $index
723722
* @link http://redis.io/commands/llen
724723
*/
725724
public function lSize( $key ) {}
@@ -1450,7 +1449,7 @@ public function expire( $key, $ttl ) {}
14501449
* Sets an expiration date (a timeout in milliseconds) on an item.
14511450
*
14521451
* @param string $key The key that will disappear.
1453-
* @param int $pttl The key's remaining Time To Live, in milliseconds.
1452+
* @param int $ttl The key's remaining Time To Live, in milliseconds.
14541453
* @return bool: TRUE in case of success, FALSE in case of failure.
14551454
* @link http://redis.io/commands/pexpire
14561455
* @example
@@ -1781,6 +1780,7 @@ public function bitCount( $key ) {}
17811780
* @param string $retKey return key
17821781
* @param string $key1
17831782
* @param string $key2
1783+
* @param string $key3
17841784
* @return int The size of the string stored in the destination key.
17851785
* @link http://redis.io/commands/bitop
17861786
* @example
@@ -2971,7 +2971,7 @@ public function _hosts() {}
29712971
public function _function() {}
29722972

29732973
/**
2974-
* @param string key The key for which you want to lookup the host
2974+
* @param string $key The key for which you want to lookup the host
29752975
* @return string the host to be used for a certain key
29762976
*/
29772977
public function _target($key) {}

0 commit comments

Comments
 (0)