Skip to content

Commit 3d55d15

Browse files
committed
refactor: Update selectPlacements parameter from placementId to identifier
Rename the public facing parameter to align with all other platforms Signed-off-by: Thomson Thomas <thomson.thomas@rokt.com>
1 parent c1e8164 commit 3d55d15

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

example/lib/rokt_layouts_screen.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ class _RoktLayoutsScreenState extends State<RoktLayoutsScreen> {
144144
.identify(identityRequest: identityRequest);
145145

146146
widget.mpInstance?.rokt.selectPlacements(
147-
placementId: _placementIdController.text,
147+
identifier: _placementIdController.text,
148148
attributes: _getAttributesForPlatform());
149149
print('${_getPlatform()} Rokt selectPlacements called');
150150
} catch (e) {

lib/mparticle_flutter_sdk.dart

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -306,20 +306,20 @@ class Rokt {
306306
static const MethodChannel _channel =
307307
const MethodChannel('mparticle_flutter_sdk');
308308

309-
/// Selects placements with a [placementId], optional [attributes], optional [roktConfig], and optional [fontFilePathMap].
309+
/// Selects placements with a [identifier], optional [attributes], optional [roktConfig], and optional [fontFilePathMap].
310310
///
311311
/// This method calls the Rokt selectPlacements API on each platform:
312312
/// - Web: mParticle.Rokt.selectPlacements()
313313
/// - Android: MParticle.getInstance()?.Rokt().selectPlacements()
314314
/// - iOS: MParticle.sharedInstance().rokt.selectPlacements()
315315
Future<void> selectPlacements({
316-
required String placementId,
316+
required String identifier,
317317
Map<String, dynamic>? attributes,
318318
RoktConfig? roktConfig,
319319
Map<String, String>? fontFilePathMap,
320320
}) async {
321321
var params = {
322-
'placementId': placementId,
322+
'placementId': identifier,
323323
'attributes': attributes,
324324
'config': _roktConfigToMap(config: roktConfig),
325325
'fontFilePathMap': fontFilePathMap,

0 commit comments

Comments
 (0)