Skip to content

Commit

Permalink
fix: remove deprecation for limit param
Browse files Browse the repository at this point in the history
  • Loading branch information
murali-shris committed Dec 13, 2024
1 parent 4d3e7f8 commit abfe512
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
5 changes: 2 additions & 3 deletions packages/at_commons/lib/src/verb/sync_verb_builder.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,8 @@ class SyncVerbBuilder implements VerbBuilder {
/// if regex is set, then only keys matching the regex will be synced from server to client
String? regex;

@Deprecated(
'This field is not used anymore even though it is set in client. Remove this in next major release')
int limit = 10;
/// Number of entries to be fetched from commit log on the server in one batch
int limit = 25;

@Deprecated(
'This field is not used anymore even though it is set in client. Remove this in next major release')
Expand Down
6 changes: 3 additions & 3 deletions packages/at_commons/test/sync_verb_builder_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ void main() {
test('build sync verb command with defaults values', () {
var syncVerbBuilder = SyncVerbBuilder()..commitId = -1;
var command = syncVerbBuilder.buildCommand();
expect(command, 'sync:from:-1:limit:10\n');
expect(command, 'sync:from:-1:limit:25\n');
var regex = RegExp(VerbSyntax.syncFrom);
command = command.replaceAll('\n', '');
assert(regex.hasMatch(command));
Expand All @@ -16,7 +16,7 @@ void main() {
..regex = '.buzz'
..commitId = -1;
var command = syncVerbBuilder.buildCommand();
expect(command, 'sync:from:-1:limit:10:.buzz\n');
expect(command, 'sync:from:-1:limit:25:.buzz\n');
var regex = RegExp(VerbSyntax.syncFrom);
command = command.replaceAll('\n', '');
assert(regex.hasMatch(command));
Expand All @@ -27,7 +27,7 @@ void main() {
..commitId = 3
..regex = '.buzz';
var command = syncVerbBuilder.buildCommand();
expect(command, 'sync:from:3:limit:10:.buzz\n');
expect(command, 'sync:from:3:limit:25:.buzz\n');
var regex = RegExp(VerbSyntax.syncFrom);
command = command.replaceAll('\n', '');
assert(regex.hasMatch(command));
Expand Down

0 comments on commit abfe512

Please sign in to comment.