Code Duplication    Length = 5-5 lines in 5 locations

src/phpFastCache/Drivers/Couchbase/Driver.php 1 location

@@ 57-61 (lines=5) @@
54
    {
55
        $this->setup($config);
56
57
        if (!$this->driverCheck()) {
58
            throw new phpFastCacheDriverCheckException(sprintf(self::DRIVER_CHECK_FAILURE, $this->getDriverName()));
59
        } else {
60
            $this->driverConnect();
61
        }
62
    }
63
64
    /**

src/phpFastCache/Drivers/Leveldb/Driver.php 1 location

@@ 49-53 (lines=5) @@
46
    {
47
        $this->setup($config);
48
49
        if (!$this->driverCheck()) {
50
            throw new phpFastCacheDriverCheckException(sprintf(self::DRIVER_CHECK_FAILURE, $this->getDriverName()));
51
        } else {
52
            $this->driverConnect();
53
        }
54
    }
55
56
    /**

src/phpFastCache/Drivers/Mongodb/Driver.php 1 location

@@ 53-57 (lines=5) @@
50
    {
51
        $this->setup($config);
52
53
        if (!$this->driverCheck()) {
54
            throw new phpFastCacheDriverCheckException(sprintf(self::DRIVER_CHECK_FAILURE, $this->getDriverName()));
55
        } else {
56
            $this->driverConnect();
57
        }
58
    }
59
60
    /**

src/phpFastCache/Drivers/Predis/Driver.php 1 location

@@ 43-47 (lines=5) @@
40
    {
41
        $this->setup($config);
42
43
        if (!$this->driverCheck()) {
44
            throw new phpFastCacheDriverCheckException(sprintf(self::DRIVER_CHECK_FAILURE, $this->getDriverName()));
45
        } else {
46
            $this->driverConnect();
47
        }
48
    }
49
50
    /**

src/phpFastCache/Drivers/Redis/Driver.php 1 location

@@ 43-47 (lines=5) @@
40
    {
41
        $this->setup($config);
42
43
        if (!$this->driverCheck()) {
44
            throw new phpFastCacheDriverCheckException(sprintf(self::DRIVER_CHECK_FAILURE, $this->getDriverName()));
45
        } else {
46
            $this->driverConnect();
47
        }
48
    }
49
50
    /**