Skip to content

Commit c190db7

Browse files
committed
feat: Support transient identities and traits
1 parent d206633 commit c190db7

8 files changed

+85
-65
lines changed

Diff for: lib/src/model/feature.g.dart

+10-12
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: lib/src/model/flag.g.dart

+9-11
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: lib/src/model/flags_and_traits.g.dart

+9-10
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: lib/src/model/identity.dart

+4
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,12 @@ part 'identity.g.dart';
66
/// Personalized user
77
@JsonSerializable()
88
class Identity {
9+
@JsonKey(includeIfNull: false)
10+
final bool? transient;
911
final String identifier;
12+
1013
const Identity({
14+
this.transient,
1115
required this.identifier,
1216
});
1317

Diff for: lib/src/model/identity.g.dart

+17-8
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: lib/src/model/trait.dart

+3
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,16 @@ part 'trait.g.dart';
88
@JsonSerializable()
99
class Trait {
1010
final int? id;
11+
@JsonKey(includeIfNull: false)
12+
final bool? transient;
1113
@JsonKey(name: 'trait_key')
1214
final String key;
1315
@JsonKey(name: 'trait_value', fromJson: _fromJson, toJson: _toJson)
1416
final dynamic value;
1517

1618
Trait({
1719
this.id,
20+
this.transient,
1821
required this.key,
1922
required this.value,
2023
});

Diff for: lib/src/model/trait.g.dart

+27-18
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: pubspec.yaml

+6-6
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ description: >-
33
Core Package of Flutter Client SDK for https://www.flagsmith.com/, Flagsmith is 100% Open
44
Source. Host yourself or let us take care of the hosting.
55
6-
version: 3.0.0
6+
version: 3.1.0
77
homepage: https://github.com/Flagsmith/flagsmith-flutter-core
88
repository: https://github.com/Flagsmith/flagsmith-flutter-core
99
issue_tracker: https://github.com/Flagsmith/flagsmith-flutter-core/issues
@@ -14,13 +14,13 @@ environment:
1414
dependencies:
1515
crypto: ^3.0.1
1616
encrypt: ^5.0.1
17-
rxdart: ^0.27.5
17+
rxdart: ^0.28.0
1818
json_annotation: ^4.0.1
1919
collection: ^1.15.0
2020
dev_dependencies:
21-
flutter_lints: ^1.0.0
22-
test: ">=1.16.0 <=1.17.12"
23-
http_mock_adapter: ^0.3.2
21+
flutter_lints: ^5.0.0
22+
test: ^1.25.8
23+
http_mock_adapter: ^0.6.1
2424
mockito: ^5.0.15
25-
json_serializable: ^4.1.3
25+
json_serializable: ^6.8.0
2626
build_runner: ^2.1.2

0 commit comments

Comments
 (0)