Forgot to save earlier
This commit is contained in:
parent
61d20f8b37
commit
55d75efa06
3 changed files with 6 additions and 3 deletions
|
|
@ -5,6 +5,7 @@ import 'package:fluffychat/pangea/controllers/language_detection_controller.dart
|
|||
import 'package:fluffychat/pangea/models/pangea_match_model.dart';
|
||||
import 'package:fluffychat/pangea/models/pangea_token_model.dart';
|
||||
import 'package:fluffychat/pangea/models/span_card_model.dart';
|
||||
import 'package:fluffychat/pangea/repo/igc_repo.dart';
|
||||
import 'package:fluffychat/pangea/utils/error_handler.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
|
@ -26,7 +27,7 @@ class IGCTextData {
|
|||
bool enableIT;
|
||||
bool enableIGC;
|
||||
bool loading = false;
|
||||
Map<String, Object?> prevMessages;
|
||||
List<PreviousMessage> prevMessages;
|
||||
|
||||
IGCTextData({
|
||||
required this.detections,
|
||||
|
|
|
|||
|
|
@ -88,7 +88,7 @@ class IgcRepo {
|
|||
userL2: "en",
|
||||
enableIT: true,
|
||||
enableIGC: true,
|
||||
prevMessages: <String, Object?>{},
|
||||
prevMessages: [],
|
||||
);
|
||||
|
||||
return igcTextData;
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ class SpanDetailsRepoReqAndRes {
|
|||
userL2: json['user_l2'] as String,
|
||||
enableIT: json['enable_it'] as bool,
|
||||
enableIGC: json['enable_igc'] as bool,
|
||||
prevMessages: json['prev_messages'],
|
||||
prevMessages: json['prev_messages'] as List<PreviousMessage>,
|
||||
span: SpanData.fromJson(json['span']),
|
||||
);
|
||||
|
||||
|
|
@ -90,6 +90,7 @@ class SpanDetailsRepoReqAndRes {
|
|||
if (other.userL2 != userL2) return false;
|
||||
if (other.enableIT != enableIT) return false;
|
||||
if (other.enableIGC != enableIGC) return false;
|
||||
if (!other.prevMessages.equals(prevMessages)) return false;
|
||||
if (const ListEquality().equals(
|
||||
other.span.choices?.sorted((a, b) => b.value.compareTo(a.value)),
|
||||
span.choices?.sorted((a, b) => b.value.compareTo(a.value)),
|
||||
|
|
@ -109,6 +110,7 @@ class SpanDetailsRepoReqAndRes {
|
|||
userL2.hashCode,
|
||||
enableIT.hashCode,
|
||||
enableIGC.hashCode,
|
||||
prevMessages.hashCode,
|
||||
if (span.choices != null)
|
||||
Object.hashAll(
|
||||
span.choices!
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue