Code Duplication    Length = 9-9 lines in 2 locations

src/Caching/MemcacheCache.php 1 location

@@ 43-51 (lines=9) @@
40
     * @param boolean $persistent If you want this connection to be persistent set to true else set to false
41
     * @return $this
42
     */
43
    public function connect($host, $port, $persistent = false)
44
    {
45
        if ($persistent === false) {
46
            $this->cache->connect($host, intval($port));
47
        } else {
48
            $this->cache->pconnect($host, intval($port));
49
        }
50
        return $this;
51
    }
52
    
53
    /**
54
     * Add a server to connection pool

src/Caching/RedisCache.php 1 location

@@ 52-60 (lines=9) @@
49
     * @param boolean $persistent If you want this connection to be persistent set to true else set to false
50
     * @return $this
51
     */
52
    public function addServer($host, $port, $persistent = false)
53
    {
54
        if ($persistent === false) {
55
            $this->cache->connect($host, intval($port));
56
        } else {
57
            $this->cache->pconnect($host, intval($port));
58
        }
59
        return $this;
60
    }
61
    
62
63
    /**