mirror of
https://github.com/lubosz/overte.git
synced 2025-04-23 13:33:38 +02:00
make localhost work again
This commit is contained in:
parent
636c271dc3
commit
7976a1f95e
1 changed files with 5 additions and 1 deletions
|
@ -329,7 +329,11 @@ void AddressManager::handleLookupString(const QString& lookupString, bool fromSu
|
|||
QString sanitizedString = lookupString.trimmed();
|
||||
QUrl lookupURL;
|
||||
|
||||
if (lookupString.toLower().startsWith(HIFI_URL_SCHEME + ":/") || isPossiblePlaceName(sanitizedString)) {
|
||||
if (lookupString.toLower().startsWith(HIFI_URL_SCHEME + ":/") ||
|
||||
isPossiblePlaceName(sanitizedString) ||
|
||||
// "localhost" isn't a valid placename, but we treat it specially here, to mean
|
||||
// "try to find an connect to the DS on the host running interface".
|
||||
lookupString.toLower() == "localhost") {
|
||||
// sometimes we need to handle lookupStrings like hifi:/somewhere
|
||||
const QRegExp HIFI_SCHEME_REGEX = QRegExp(HIFI_URL_SCHEME + ":\\/{1,2}", Qt::CaseInsensitive);
|
||||
sanitizedString = sanitizedString.remove(HIFI_SCHEME_REGEX);
|
||||
|
|
Loading…
Reference in a new issue