Skip to content

Commit

Permalink
Fix parsing QueryEmailResponse
Browse files Browse the repository at this point in the history
  • Loading branch information
dab246 authored and hoangdat committed Jul 9, 2024
1 parent dab0775 commit 0e88c47
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 14 deletions.
4 changes: 2 additions & 2 deletions lib/jmap/core/method/response/query_response.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ abstract class QueryResponse extends ResponseRequiringAccountId {
final bool canCalculateChanges;
final UnsignedInt position;
final Set<Id> ids;
final UnsignedInt total;
final UnsignedInt limit;
final UnsignedInt? total;
final UnsignedInt? limit;

QueryResponse(
AccountId accountId,
Expand Down
5 changes: 3 additions & 2 deletions lib/jmap/mail/email/query/query_email_response.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import 'package:jmap_dart_client/http/converter/account_id_converter.dart';
import 'package:jmap_dart_client/http/converter/id_converter.dart';
import 'package:jmap_dart_client/http/converter/state_converter.dart';
import 'package:jmap_dart_client/http/converter/unsigned_int_converter.dart';
import 'package:jmap_dart_client/http/converter/unsigned_int_nullable_converter.dart';
import 'package:jmap_dart_client/jmap/account_id.dart';
import 'package:jmap_dart_client/jmap/core/id.dart';
import 'package:jmap_dart_client/jmap/core/method/response/query_response.dart';
Expand All @@ -24,8 +25,8 @@ class QueryEmailResponse extends QueryResponse {
bool canCalculateChanges,
UnsignedInt position,
Set<Id> ids,
UnsignedInt total,
UnsignedInt limit,
UnsignedInt? total,
UnsignedInt? limit,
) : super(accountId, queryState, canCalculateChanges, position, ids, total, limit);

factory QueryEmailResponse.fromJson(Map<String, dynamic> json) => _$QueryEmailResponseFromJson(json);
Expand Down
8 changes: 4 additions & 4 deletions lib/jmap/mail/email/query/query_email_response.g.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions lib/jmap/mail/mailbox/query/query_mailbox_response.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import 'package:jmap_dart_client/http/converter/account_id_converter.dart';
import 'package:jmap_dart_client/http/converter/id_converter.dart';
import 'package:jmap_dart_client/http/converter/state_converter.dart';
import 'package:jmap_dart_client/http/converter/unsigned_int_converter.dart';
import 'package:jmap_dart_client/http/converter/unsigned_int_nullable_converter.dart';
import 'package:jmap_dart_client/jmap/account_id.dart';
import 'package:jmap_dart_client/jmap/core/id.dart';
import 'package:jmap_dart_client/jmap/core/method/response/query_response.dart';
Expand All @@ -24,8 +25,8 @@ class QueryMailboxResponse extends QueryResponse {
bool canCalculateChanges,
UnsignedInt position,
Set<Id> ids,
UnsignedInt total,
UnsignedInt limit,
UnsignedInt? total,
UnsignedInt? limit,
) : super(accountId, queryState, canCalculateChanges, position, ids, total, limit);

factory QueryMailboxResponse.fromJson(Map<String, dynamic> json) => _$QueryMailboxResponseFromJson(json);
Expand Down
8 changes: 4 additions & 4 deletions lib/jmap/mail/mailbox/query/query_mailbox_response.g.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 0e88c47

Please sign in to comment.