You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// Retrieves the `SharedState` for a specific extension/// - Parameters:/// - extensionName: An extension name whose `SharedState` will be returned/// - event: If not nil, will retrieve the `SharedState` that corresponds with this event's version. If nil will return the latest `SharedState`/// - barrier: If true, the `EventHub` will only return `.set` if `extensionName` has moved past `event`/// - sharedStateType: The type of shared state to be read from, if not provided defaults to `.standard`/// - Returns: The `SharedState` data and status for the extension with `extensionName`
From the above public API doc, getSharedState() should return the latest SharedState if the given even is nil.
Talked with @shalehaha the current implementation is desired, however, somehow the doc comment got out of sync. To resolve this issue I think we just need to update the doc comment.
Expected Behaviour
From the above public API doc, getSharedState() should return the latest
SharedState
if the given even is nil.Actual Behaviour
aepsdk-core-ios/AEPCore/Sources/eventhub/EventHub.swift
Line 233 in 9fe6554
SharedState.resolve() will return the oldest one if the event version is 0.
Reproduce Scenario (including but not limited to)
Steps to Reproduce
Platform and Version
Sample Code that illustrates the problem
Logs taken while reproducing problem
The text was updated successfully, but these errors were encountered: