mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-05-01 14:13:22 +01:00
Ensure ACI/PNI are associated after processing a PNI promotion message.
This commit is contained in:
committed by
Cody Henthorne
parent
15f1201a76
commit
4a0abbbee7
@@ -197,6 +197,10 @@ sealed class ServiceId(val libSignalServiceId: LibSignalServiceId) {
|
||||
}
|
||||
}
|
||||
|
||||
/** Parses a [ByteString] as a PNI, regardless if the `PNI:` prefix is present or not. Only use this if you are certain that what you're reading is a PNI. */
|
||||
@JvmStatic
|
||||
fun parseOrNull(bytes: ByteString): PNI? = parseOrNull(bytes.toByteArray())
|
||||
|
||||
/** Parses a string as a PNI, regardless if the `PNI:` prefix is present or not. Only use this if you are certain that what you're reading is a PNI. */
|
||||
@JvmStatic
|
||||
@Throws(IllegalArgumentException::class)
|
||||
|
||||
Reference in New Issue
Block a user