migrate Content classes to primary constructors

The Riverpod bug preventing us from doing this has been fixed.
This commit is contained in:
Henry Hiles 2026-10-23 20:44:29 -04:00
commit dd01ad9d74
Signed by: Henry-Hiles
SSH key fingerprint: SHA256:VKQUdS31Q90KvX7EkKMHMBpUspcmItAh86a+v7PGiIs

View file

@ -3,10 +3,11 @@ import "package:nexus/models/content/content.dart";
part "encrypted.freezed.dart";
part "encrypted.g.dart";
@freezed
sealed class EncryptedContent extends Content with _$EncryptedContent {
EncryptedContent._();
factory EncryptedContent() = _EncryptedContent;
@Freezed(toJson: false, fromJson: false)
@JsonSerializable()
class const EncryptedContent() extends Content with _$EncryptedContent {
@override
Map<String, Object?> toJson() => _$EncryptedContentToJson(this);
factory EncryptedContent.fromJson(Map<String, Object?> json) =>
_$EncryptedContentFromJson(json);