Code Duplication    Length = 9-9 lines in 2 locations

class/adodb.php 1 location

@@ 242-250 (lines=9) @@
239
	 */
240
	public function Connect ($forcenew = false) {
241
		// Mysqli doesn't allow port in host, grab it out and set
242
		if ('mysqli' == strtolower($this->__conn->databaseType)) {
243
			$ar = array();
244
			$i = preg_match('/:(\d+)$/', $this->aDbProfile['host'], $ar);
245
			if (0 < $i) {
246
				$this->__conn->port = $ar[1];
247
				$this->aDbProfile['host'] = preg_replace('/:(\d+)$/', ''
248
					, $this->aDbProfile['host']);
249
			}
250
		}
251
252
253
		try {

src/Fwlib/Bridge/Adodb.php 1 location

@@ 284-292 (lines=9) @@
281
282
        // @codeCoverageIgnoreStart
283
        // Mysqli doesn't allow port in host, grab it out and set
284
        if ('mysqli' == strtolower($this->conn->databaseType)) {
285
            $ar = [];
286
            $i = preg_match('/:(\d+)$/', $this->profile['host'], $ar);
287
            if (0 < $i) {
288
                $this->conn->port = $ar[1];
289
                $this->profile['host'] =
290
                    preg_replace('/:(\d+)$/', '', $this->profile['host']);
291
            }
292
        }
293
        // @codeCoverageIgnoreEnd
294
295