fix(crawler): Fix invalid calculation of number of first vaccinations

Numbers for second shot are actually inclusive of booster
shots, so booster shots do not
have to be subtracted from the
total number of vaccinations.

Fixes #10.
This commit is contained in:
Adrian Rumpold
2021-11-11 19:50:44 +01:00
parent a44308a4e1
commit f6f799e85f

View File

@@ -187,8 +187,8 @@ class CovidCrawler(CovidCrawlerBase):
if not matches:
raise ValueError(f"Could not extract date from scraped web page, {text=}")
values["num_vaccinated_once"] = values["total_vaccinations"] - (
values["num_vaccinated_full"] + values["num_vaccinated_booster"]
values["num_vaccinated_once"] = (
values["total_vaccinations"] - values["num_vaccinated_full"]
)
values["date"] = parse_date(**matches.groupdict()).strftime("%Y-%m-%d")