added brace wrapping after if and for

This commit is contained in:
fourtf
2018-10-21 13:43:02 +02:00
parent c6e1ec3c71
commit e259b9e39f
138 changed files with 4738 additions and 2237 deletions
+12 -6
View File
@@ -48,16 +48,21 @@ void DownloadManager::onDownloadProgress(qint64 bytesRead, qint64 bytesTotal)
void DownloadManager::onFinished(QNetworkReply *reply)
{
switch (reply->error()) {
case QNetworkReply::NoError: {
switch (reply->error())
{
case QNetworkReply::NoError:
{
qDebug("file is downloaded successfully.");
} break;
default: {
}
break;
default:
{
qDebug() << reply->errorString().toLatin1();
};
}
if (file->isOpen()) {
if (file->isOpen())
{
file->close();
file->deleteLater();
}
@@ -71,7 +76,8 @@ void DownloadManager::onReadyRead()
void DownloadManager::onReplyFinished()
{
if (file->isOpen()) {
if (file->isOpen())
{
file->close();
file->deleteLater();
}