fix: preserve mobile bootstrap auth fallback (#60238) (thanks @ngutman)

This commit is contained in:
Peter Steinberger
2026-04-04 15:55:24 +09:00
parent 226ca1f324
commit 20266ff7dd
7 changed files with 318 additions and 13 deletions

View File

@@ -1064,10 +1064,8 @@ export function attachGatewayWsMessageHandler(params: {
issuedAtMs: deviceToken.rotatedAtMs ?? deviceToken.createdAtMs,
});
}
const bootstrapProfileForHello: DeviceBootstrapProfile | null = device
? bootstrapProfile
: null;
if (device && bootstrapProfileForHello !== null) {
if (device && bootstrapProfile !== null) {
const bootstrapProfileForHello = bootstrapProfile as DeviceBootstrapProfile;
for (const bootstrapRole of bootstrapProfileForHello.roles) {
if (bootstrapDeviceTokens.some((entry) => entry.role === bootstrapRole)) {
continue;