diff --git a/infodb-source-onet/src/main/java/ovh/eukon05/infodb/source/onet/OnetArticleMapper.java b/infodb-source-onet/src/main/java/ovh/eukon05/infodb/source/onet/OnetArticleMapper.java index 78c3b04..3980d3f 100644 --- a/infodb-source-onet/src/main/java/ovh/eukon05/infodb/source/onet/OnetArticleMapper.java +++ b/infodb-source-onet/src/main/java/ovh/eukon05/infodb/source/onet/OnetArticleMapper.java @@ -3,7 +3,7 @@ import org.jsoup.nodes.Element; import ovh.eukon05.infodb.api.source.Article; -import java.time.OffsetDateTime; +import java.time.ZonedDateTime; import java.time.format.DateTimeFormatter; final class OnetArticleMapper { @@ -26,7 +26,7 @@ static Article mapFromHtml(Element articleElement, OnetArticleDetails details) { String title = articleElement.getElementsByTag("span").text(); // Article will have its publication time shifted to the UTC timezone this way! - OffsetDateTime pubDate = OffsetDateTime.parse(details.pubDate(), DTF); + ZonedDateTime pubDate = ZonedDateTime.parse(details.pubDate(), DTF); return new Article(id, PROVIDER, title, url, imageUrl, pubDate.toInstant(), details.tags()); }