Skip to content

Commit

Permalink
[Communication][Chat] Revert reference on .cloudEnvironment to its pr…
Browse files Browse the repository at this point in the history
…evious name (#1630)

* Revert .cloudEnvironment to its previous name

* Remove unused function

- parse(id:, prefix:) was previously used in getIdentifier(from:) that
  no longer exist
  • Loading branch information
cheukchuen authored Oct 10, 2023
1 parent 67f52b0 commit b1e36a4
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,3 @@ func isGcch(id: String) -> Bool {
let gcchAcsUserPrefix = "gcch-acs:"
return (id.starts(with: gcchTeamsUserPrefix) || id.starts(with: gcchAcsUserPrefix))
}

/// Parses out the id/phone number portion of a user id.
/// - Parameters:
/// - id: The string id.
/// - prefix: The id prefix.
/// - Returns: The part of the id after the prefix that corresponds to the user id or phone number of a user.
private func parse(id: String, prefix: String) -> String {
let index = id.index(id.startIndex, offsetBy: prefix.count)
return String(id.suffix(from: index))
}
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ internal enum IdentifierSerializer {
.isAnonymous,
cloud: serialize(
cloud: teamsUser
.cloudEnvironment
.cloudEnviroment
)
)
)
Expand Down

0 comments on commit b1e36a4

Please sign in to comment.