Code Duplication    Length = 7-7 lines in 3 locations

src/storage/Repository.php 1 location

@@ 225-231 (lines=7) @@
222
    /**
223
     * @return \PDO
224
     */
225
    protected function getContentDbHandle()
226
    {
227
        if ($this->contentDbHandle === null) {
228
            $this->contentDbHandle = new \PDO('sqlite:' . $this->storagePath . DIRECTORY_SEPARATOR . 'content.db');
229
        }
230
        return $this->contentDbHandle;
231
    }
232
233
    private function initConfigIfNotExists($json, $subsetName)
234
    {

src/storage/repository/ContentRepository.php 1 location

@@ 29-35 (lines=7) @@
26
        /**
27
         * @return \PDO
28
         */
29
        public function getContentDbHandle()
30
        {
31
            if ($this->contentDbHandle === null) {
32
                $this->contentDbHandle = new \PDO('sqlite:' . $this->storagePath . DIRECTORY_SEPARATOR . 'content.db');
33
            }
34
            return $this->contentDbHandle;
35
        }
36
37
        /**
38
         * Prepare the sql statement

src/storage/Cache.php 1 location

@@ 98-104 (lines=7) @@
95
    /**
96
     * @return \PDO
97
     */
98
    private function getDbInstance()
99
    {
100
        if ($this->dbHandle === null) {
101
            $this->dbHandle = new \PDO('sqlite:' . $this->storagePath . DIRECTORY_SEPARATOR . 'cache.db');
102
        }
103
        return $this->dbHandle;
104
    }
105
106
    /**
107
     * @param $baseCacheSqlPath