Skip to content

Commit

Permalink
Fix: disable one call url call (ooops...). Bump to version 1.30.1
Browse files Browse the repository at this point in the history
  • Loading branch information
FelixdelasPozas committed Sep 20, 2024
1 parent 3022ce3 commit baea4ec
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 11 deletions.
2 changes: 1 addition & 1 deletion AboutDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#include <QDateTime>
#include <QApplication>

const QString AboutDialog::VERSION{"1.30.0"};
const QString AboutDialog::VERSION{"1.30.1"};
const QString COPYRIGHT{"Copyright (c) 2016-%1 Félix de las Pozas Álvarez"};

//-----------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ project(TrayWeather)
# Version Number
set (TRAYWEATHER_VERSION_MAJOR 1)
set (TRAYWEATHER_VERSION_MINOR 30)
set (TRAYWEATHER_VERSION_PATCH 0)
set (TRAYWEATHER_VERSION_PATCH 1)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
Expand Down
12 changes: 6 additions & 6 deletions TrayWeather.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1096,12 +1096,12 @@ void TrayWeather::requestForecastData()
.arg(m_configuration.owm_apikey)};
m_netManager->get(QNetworkRequest{url});

url = QUrl{QString("http://api.openweathermap.org/data/2.5/onecall?lat=%1&lon=%2&lang=%3&exclude=minutely&units=%4&appid=%5").arg(m_configuration.latitude)
.arg(m_configuration.longitude)
.arg(lang)
.arg(unitsToText(m_configuration.units))
.arg(m_configuration.owm_apikey)};
m_netManager->get(QNetworkRequest{url});
// url = QUrl{QString("http://api.openweathermap.org/data/2.5/onecall?lat=%1&lon=%2&lang=%3&exclude=minutely&units=%4&appid=%5").arg(m_configuration.latitude)
// .arg(m_configuration.longitude)
// .arg(lang)
// .arg(unitsToText(m_configuration.units))
// .arg(m_configuration.owm_apikey)};
// m_netManager->get(QNetworkRequest{url});
}

//--------------------------------------------------------------------
Expand Down
4 changes: 4 additions & 0 deletions Utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,10 @@ QDebug operator <<(QDebug d, const ForecastData& data)
//--------------------------------------------------------------------
void parseForecastEntry(const QJsonObject& entry, ForecastData& data)
{
const auto keys = entry.keys();
if(!keys.contains("main"))
return;

const auto main = entry.value("main").toObject();
const auto weather = entry.value("weather").toArray().first().toObject();
const auto wind = entry.value("wind").toObject();
Expand Down
6 changes: 3 additions & 3 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -163,16 +163,16 @@ To the translation in your language. For example in Spanish it is:

# Repository information

**Version**: 1.30.0
**Version**: 1.30.1

**Status**: finished.

**cloc statistics**

| Language |files |blank |comment |code |
|:-----------------------------|--------------:|------------:|-----------------:|-----:|
| C++ | 11 | 1135 | 761 | 5200 |
| C++ | 11 | 1136 | 767 | 5197 |
| C/C++ Header | 11 | 309 | 920 | 992 |
| HTML | 1 | 33 | 0 | 152 |
| CMake | 1 | 19 | 11 | 127 |
| **Total** | **24** | **1496** | **1692** | **6471** |
| **Total** | **24** | **1497** | **1698** | **6468** |

0 comments on commit baea4ec

Please sign in to comment.