Skip to content

Commit

Permalink
Fix in memcache.php
Browse files Browse the repository at this point in the history
  • Loading branch information
pedroresende committed Mar 27, 2013
1 parent 071352c commit 6a51da9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Stash/Driver/Sub/Memcache.php
Expand Up @@ -30,9 +30,9 @@ public function initialize($servers, array $options = array())
$memcache = new \Memcache(); $memcache = new \Memcache();


foreach ($servers as $server) { foreach ($servers as $server) {
$host = $server[0]; $host = $server['server'];
$port = isset($server[1]) ? $server[1] : 11211; $port = isset($server['port']) ? $server['port'] : 11211;
$weight = isset($server[2]) ? (int)$server[2] : null; $weight = isset($server['weight']) ? (int)$server['weight'] : null;


if (is_integer($weight)) { if (is_integer($weight)) {
$memcache->addServer($host, $port, true, $weight); $memcache->addServer($host, $port, true, $weight);
Expand Down

0 comments on commit 6a51da9

Please sign in to comment.