Skip to content

Commit

Permalink
fix: handle reseting apiHost to null
Browse files Browse the repository at this point in the history
  • Loading branch information
oscb committed Apr 10, 2024
1 parent 6030a47 commit fc15b18
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions packages/core/lib/plugins/segment_destination.dart
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,7 @@ class SegmentDestination extends DestinationPlugin with Flushable {
@override
void update(Map<String, dynamic> settings, ContextUpdateType type) {
super.update(settings, type);
if (settings[segmentDestinationKey] != null &&
settings[segmentDestinationKey]['apiHost'] != null) {
_apiHost = '${settings[segmentDestinationKey]['apiHost']}';
}
_apiHost = settings[segmentDestinationKey]?['apiHost'];
}

@override
Expand Down

0 comments on commit fc15b18

Please sign in to comment.