22 lines
547 B
Swift
22 lines
547 B
Swift
//
|
|
// Copyright 2022-2024 New Vector Ltd.
|
|
//
|
|
// SPDX-License-Identifier: AGPL-3.0-only
|
|
// Please see LICENSE in the repository root for full details.
|
|
//
|
|
|
|
import Foundation
|
|
import MatrixSDK
|
|
|
|
extension MXSession {
|
|
|
|
/// Convenient getter to retrieve UserLocationService associated to session user id
|
|
var userLocationService: UserLocationServiceProtocol? {
|
|
guard let myUserId = self.myUserId else {
|
|
return nil
|
|
}
|
|
|
|
return UserLocationServiceProvider.shared.locationService(for: myUserId)
|
|
}
|
|
}
|