mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-27 11:05:44 +08:00
Log messages when URL for news/help is missing
Found during Ref T32
This commit is contained in:
@@ -533,7 +533,11 @@ namespace BlackGui
|
|||||||
{
|
{
|
||||||
const CGlobalSetup gs = this->getGlobalSetup();
|
const CGlobalSetup gs = this->getGlobalSetup();
|
||||||
const CUrl helpPage = gs.getHelpPageUrl();
|
const CUrl helpPage = gs.getHelpPageUrl();
|
||||||
if (helpPage.isEmpty()) { return; }
|
if (helpPage.isEmpty())
|
||||||
|
{
|
||||||
|
CLogMessage(this).warning("No help page");
|
||||||
|
return;
|
||||||
|
}
|
||||||
QDesktopServices::openUrl(helpPage);
|
QDesktopServices::openUrl(helpPage);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -184,7 +184,11 @@ void CSwiftLauncher::loadLatestNews()
|
|||||||
{
|
{
|
||||||
CFailoverUrlList newsUrls(sGui->getGlobalSetup().getSwiftLatestNewsUrls());
|
CFailoverUrlList newsUrls(sGui->getGlobalSetup().getSwiftLatestNewsUrls());
|
||||||
const CUrl newsUrl(newsUrls.obtainNextWorkingUrl());
|
const CUrl newsUrl(newsUrls.obtainNextWorkingUrl());
|
||||||
if (newsUrl.isEmpty()) { return; }
|
if (newsUrl.isEmpty())
|
||||||
|
{
|
||||||
|
CLogMessage(this).error("No working news URL in %1") << newsUrls.toQString();
|
||||||
|
return;
|
||||||
|
}
|
||||||
sGui->getFromNetwork(newsUrl, { this, &CSwiftLauncher::ps_displayLatestNews});
|
sGui->getFromNetwork(newsUrl, { this, &CSwiftLauncher::ps_displayLatestNews});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user