Code Duplication    Length = 10-12 lines in 2 locations

lib/Config/Storage/RelationalDatabase.php 2 locations

@@ 135-146 (lines=12) @@
132
        return $check && $check['cnt'] > 0;
133
    }
134
135
    protected function doInsert(Sql $sql, $path, $value, $context)
136
    {
137
        $insert = $sql->insert(self::TABLE);
138
        $insert->values([
139
            'path'      => $path,
140
            'value'     => $value,
141
            'context'   => $context
142
        ]);
143
        $insert = $insert->getSqlString($this->adapter->getPlatform());
144
145
        $this->adapter->query($insert)->execute();
146
    }
147
148
    protected function doUpdate(Sql $sql, $path, $value, $context)
149
    {
@@ 148-157 (lines=10) @@
145
        $this->adapter->query($insert)->execute();
146
    }
147
148
    protected function doUpdate(Sql $sql, $path, $value, $context)
149
    {
150
        $update = $sql->update(self::TABLE);
151
        $update->set([
152
            'value' => $value
153
        ])->where(['path' => $path, 'context' => $context]);
154
155
        $update = $update->getSqlString($this->adapter->getPlatform());
156
        $this->adapter->query($update)->execute();
157
    }
158
159
    public function create()
160
    {