From 6ec8277acce378b4f3a7b3c228cc75a53b8e4959 Mon Sep 17 00:00:00 2001 From: Dillon Nys Date: Mon, 19 Feb 2024 15:49:18 -0800 Subject: [PATCH] chore(core): JsonList/Map should implement raw type --- .../lib/src/serialization/json_value.dart | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/packages/celest_core/lib/src/serialization/json_value.dart b/packages/celest_core/lib/src/serialization/json_value.dart index 2445a685..ba0a84cb 100644 --- a/packages/celest_core/lib/src/serialization/json_value.dart +++ b/packages/celest_core/lib/src/serialization/json_value.dart @@ -87,17 +87,12 @@ extension type const JsonDouble(double value) implements JsonNum, double { extension type const JsonBool(bool value) implements JsonValue, bool {} /// A [JsonValue] which represents a [List]. -extension type const JsonList._(List value) - implements JsonValue, List { - const JsonList(List value) : this._(value as List); -} +extension type const JsonList(List value) + implements JsonValue, List {} /// A [JsonValue] which represents a [Map]. -extension type const JsonMap._(Map value) - implements JsonValue, Map { - const JsonMap(Map value) - : this._(value as Map); - +extension type const JsonMap(Map value) + implements JsonValue, Map { /// Returns the string associated with [key] or `null` if [key] is not in the /// map. JsonString? optionalString(String key) {