mirror of
https://github.com/searxng/searxng.git
synced 2025-08-11 09:13:45 -04:00
[fix] legacy results: published date missing (#5093)
The `publishedDate` has always been `None` before that change, which causes that there are no `publishedDate`s visible for any result.
This commit is contained in:
parent
dd170964c7
commit
761b74e8c9
@ -446,7 +446,7 @@ class LegacyResult(dict):
|
||||
positions: list[int]
|
||||
score: float
|
||||
category: str
|
||||
publishedDate: datetime.datetime | None = None
|
||||
publishedDate: datetime.datetime | None
|
||||
pubdate: str = ""
|
||||
|
||||
# infobox result
|
||||
@ -476,6 +476,7 @@ class LegacyResult(dict):
|
||||
self["positions"] = self.get("positions", "")
|
||||
self["score"] = self.get("score", 0)
|
||||
self["category"] = self.get("category", "")
|
||||
self["publishedDate"] = self.get("publishedDate")
|
||||
|
||||
if "infobox" in self:
|
||||
self["urls"] = self.get("urls", [])
|
||||
|
Loading…
x
Reference in New Issue
Block a user