Showing the changes to libraries/script-engine/src/XMLHttpRequestClass.cpp (1 of 1 file). Show all
Unified · Split
| @@ -22,6 +22,8 @@ · 21 unmodified lines | ||
| 22 | 22 | #include "XMLHttpRequestClass.h" |
| 23 | 23 | #include "ScriptEngine.h" |
| 24 | 24 | |
| 25 | +const QString METAVERSE_API_URL = "https://metaverse.highfidelity.com/api/"; | |
| 26 | + | |
| 25 | 27 | Q_DECLARE_METATYPE(QByteArray*) |
| 26 | 28 | |
| 27 | 29 | XMLHttpRequestClass::XMLHttpRequestClass(QScriptEngine* engine) : |
| @@ -207,7 +209,7 @@ void XMLHttpRequestClass::open(const QString& method, const QString& url, bool a · 179 unmodified lines | ||
| 207 | 209 | notImplemented(); |
| 208 | 210 | } |
| 209 | 211 | } else { |
| 210 | − if (url.toLower().left(39) == "https://metaverse.highfidelity.com/api/") { | |
| 212 | + if (url.toLower().left(METAVERSE_API_URL.length()) == METAVERSE_API_URL) { | |
| 211 | 213 | AccountManager& accountManager = AccountManager::getInstance(); |
| 212 | 214 | |
| 213 | 215 | if (accountManager.hasValidAccessToken()) { |