async def METHOD_NAME(tracker_payload, is_static=False) -> Optional[Profile]:
    """
    Loads current profile. If profile was merged then it loads merged profile.
    @throws DuplicatedRecordException
    """
    if tracker_payload.profile is None:
        return None
    profile_id = tracker_payload.profile.id
    try:
        profile_record = await load_by_id(profile_id)
        if profile_record is None:
            # Static profiles can be None as they need to be created if does not exist.
            # Static means the profile id was given in the track payload
            if is_static:
                return Profile(id=tracker_payload.profile.id)
            return None
        profile = Profile.create(profile_record)
        return profile
    except DuplicatedRecordException:
        return await deduplicate_profile(profile_id)