Just don't cache distro_series for now

This commit is contained in:
Simon Quigley 2024-12-18 18:35:18 -06:00
parent aa0f4d4365
commit 8d07441f9c
2 changed files with 4 additions and 4 deletions

View File

@ -27,7 +27,7 @@ source_package_publishing_history::source_package_publishing_history()
lp(nullptr),
distro_series([this]() -> std::optional<class distro_series> {
if (distro_series_link.empty()) return std::nullopt;
if (_distro_series) return _distro_series;
//if (_distro_series) return _distro_series;
auto response = lp ? lp->api_get(distro_series_link) : std::nullopt;
if (!response) return std::nullopt;
@ -37,8 +37,8 @@ source_package_publishing_history::source_package_publishing_history()
if (ds) {
ds->set_lp(lp);
_distro_series = ds.value();
return _distro_series;
//_distro_series = ds.value();
return ds;
}
return std::nullopt;

View File

@ -58,7 +58,7 @@ public:
private:
launchpad* lp;
std::optional<class distro_series> _distro_series = std::nullopt;
//std::optional<class distro_series> _distro_series = std::nullopt;
};
#endif // SOURCE_PACKAGE_PUBLISHING_HISTORY