From 9b08a982d5cebbc5c2ccbd466e047198fe0c16fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82?= Date: Tue, 10 Oct 2023 01:31:39 +0200 Subject: [PATCH] =?UTF-8?q?`fromMap`=20=E2=86=92=20`fromObject`=20as=20per?= =?UTF-8?q?=20changelog?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- zapisy/apps/notifications/assets/components/Widget.vue | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/zapisy/apps/notifications/assets/components/Widget.vue b/zapisy/apps/notifications/assets/components/Widget.vue index d4cfc43329..a31757095d 100644 --- a/zapisy/apps/notifications/assets/components/Widget.vue +++ b/zapisy/apps/notifications/assets/components/Widget.vue @@ -8,7 +8,7 @@ import relativeTime from "dayjs/plugin/relativeTime"; import utc from "dayjs/plugin/utc"; import timezone from "dayjs/plugin/timezone"; import "dayjs/locale/pl"; -import { parse, ParseFn, fromMap, aString, anArrayContaining } from "spicery"; +import { parse, ParseFn, fromObject, aString, anArrayContaining } from "spicery"; import Vue from "vue"; import Component from "vue-class-component"; @@ -24,10 +24,10 @@ class Notification { // Defines a parser that validates and parses Notifications from JSON. const notifications: ParseFn = (x: any) => new Notification( - fromMap(x, "id", aString), - fromMap(x, "description", aString), - fromMap(x, "issued_on", aString), - fromMap(x, "target", aString) + fromObject(x, "id", aString), + fromObject(x, "description", aString), + fromObject(x, "issued_on", aString), + fromObject(x, "target", aString) ); const notificationsArray = anArrayContaining(notifications);