diff --git a/src/system/SystemComponent.h b/src/system/SystemComponent.h index ff0011d..9e8190b 100644 --- a/src/system/SystemComponent.h +++ b/src/system/SystemComponent.h @@ -44,7 +44,7 @@ public: Q_INVOKABLE void cancelServerConnectivity(); Q_SIGNAL void serverConnectivityResult(QString url, bool success, QString resolvedUrl); - QString extractBaseUrl(const QString& url); + static QString extractBaseUrl(const QString& url); void resolveUrl(const QString& url, std::function callback); Q_INVOKABLE QString getUserAgent(); diff --git a/tests/test_systemcomponent.cpp b/tests/test_systemcomponent.cpp index 49168c7..86c5d07 100644 --- a/tests/test_systemcomponent.cpp +++ b/tests/test_systemcomponent.cpp @@ -141,8 +141,7 @@ void TestSystemComponent::testExtractBaseUrl() QFETCH(QString, input); QFETCH(QString, expected); - SystemComponent* component = &SystemComponent::Get(); - QString result = component->extractBaseUrl(input); + QString result = SystemComponent::extractBaseUrl(input); QCOMPARE(result, expected); }