src/Codeception/Module/WPDb.php
public function _replaceUrlInDump($sql)
    {
        if ($this->config['urlReplacement'] === false) {
            return $sql;
        }

        $this->dbDump->setTablePrefix($this->config['tablePrefix']);
        $this->dbDump->setUrl($this->config['url']);

        if (\is_array($sql)) {
            $sql = $this->dbDump->replaceSiteDomainInSqlArray($sql);
            $sql = $this->dbDump->replaceSiteDomainInMultisiteSqlArray($sql);
        } else {
            $sql = $this->dbDump->replaceSiteDomainInSqlString($sql, true);
            $sql = $this->dbDump->replaceSiteDomainInMultisiteSqlString($sql, true);
        }

        return $sql;
    }
public function _replaceUrlInDump($sql)
    {
        if ($this->config['urlReplacement'] === false) {
            return $sql;
        }

        $this->dbDump->setTablePrefix($this->config['tablePrefix']);
        $this->dbDump->setUrl($this->config['url']);

        if (\is_array($sql)) {
            $sql = $this->dbDump->replaceSiteDomainInSqlArray($sql);
            $sql = $this->dbDump->replaceSiteDomainInMultisiteSqlArray($sql);
        } else {
            $sql = $this->dbDump->replaceSiteDomainInSqlString($sql, true);
            $sql = $this->dbDump->replaceSiteDomainInMultisiteSqlString($sql, true);
        }

        return $sql;
    }
public function _replaceUrlInDump ( $ sql ) { if ( $ this -> config [ 'urlReplacement' ] === false ) { return $ sql ; } $ this -> dbDump -> setTablePrefix ( $ this -> config [ 'tablePrefix' ] ) ; $ this -> dbDump -> setUrl ( $ this -> config [ 'url' ] ) ; if ( \ is_array ( $ sql ) ) { $ sql = $ this -> dbDump -> replaceSiteDomainInSqlArray ( $ sql ) ; $ sql = $ this -> dbDump -> replaceSiteDomainInMultisiteSqlArray ( $ sql ) ; } else { $ sql = $ this -> dbDump -> replaceSiteDomainInSqlString ( $ sql , true ) ; $ sql = $ this -> dbDump -> replaceSiteDomainInMultisiteSqlString ( $ sql , true ) ; } return $ sql ; }
Replaces the URL hard-coded in the database with the one set in the the config if required.

@param string|array $sql The SQL dump string or strings.

@return array|string The SQL dump string, or strings, with the hard-coded URL replaced.
Replaces the URL hard - coded in the database with the one set in the the config if required .