DmitryDulepov\Realurl\Hooks\DataHandler::clearAutoConfiguration PHP Method

clearAutoConfiguration() protected method

Clears automatic configuration when necessary. Note: we do not check if it iss enabled. Even if now it is disabled, later it can be re-enabled and suddenly obsolete config will be used. So we clear always.
protected clearAutoConfiguration ( string $tableName, array $databaseData )
$tableName string
$databaseData array
    protected function clearAutoConfiguration($tableName, array $databaseData)
    {
        if ($tableName === 'sys_domain' || $tableName === 'pages' && isset($databaseData['is_siteroot'])) {
            if (file_exists(PATH_site . TX_REALURL_AUTOCONF_FILE)) {
                @unlink(PATH_site . TX_REALURL_AUTOCONF_FILE);
            }
        }
    }