Olivier Massot преди 1 година
родител
ревизия
113baa96b6
променени са 1 файла, в които са добавени 2 реда и са изтрити 2 реда
  1. 2 2
      components/News/Details.vue

+ 2 - 2
components/News/Details.vue

@@ -128,11 +128,11 @@ const getImageUrl = (attachment: string | null): string | null => {
 }
 
 const formattedPublicationDate: ComputedRef<string> = computed(() => {
-  if (!newsItem || !newsItem.startPublication) {
+  if (!newsItem) {
     return ''
   }
 
-  const date = parseISO(newsItem.startPublication)
+  const date = parseISO(newsItem.startPublication!)
 
   let formattedPublicationDate = format(date, "'Le' dd MMMM yyyy", {
     locale: fr,