Avoid repeating the return type

This commit is contained in:
thalieht 2019-02-14 19:16:42 +02:00
parent 9959a901fe
commit 8c944bd4e1
34 changed files with 123 additions and 123 deletions

View file

@ -464,7 +464,7 @@ namespace
offset = parts[2].toInt(&ok[0]) * 3600;
int offsetMin = parts[3].toInt(&ok[1]);
if (!ok[0] || !ok[1] || offsetMin > 59)
return QDateTime();
return {};
offset += offsetMin * 60;
negOffset = (parts[1] == QLatin1String("-"));
if (negOffset)
@ -494,7 +494,7 @@ namespace
for (int i = 0, end = zone.size(); (i < end) && !nonalpha; ++i)
nonalpha = !isalpha(zone[i]);
if (nonalpha)
return QDateTime();
return {};
// TODO: Attempt to recognize the time zone abbreviation?
negOffset = true; // unknown time zone: RFC 2822 treats as '-0000'
}