ntf: fix TRPL to send verification to the new token (#456)

This commit is contained in:
Evgeny Poberezkin 2022-07-02 15:07:20 +01:00 committed by GitHub
parent 57d83ae42d
commit 2c52c514c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -376,8 +376,9 @@ client NtfServerClient {rcvQ, sndQ} NtfSubscriber {newSubQ, smpAgent = ca} NtfPu
atomically $ do
removeTokenRegistration st tkn
writeTVar tknStatus NTRegistered
addNtfToken st tknId tkn {token = token', tknRegCode = regCode}
writeTBQueue pushQ (tkn, PNVerification regCode)
let tkn' = tkn {token = token', tknRegCode = regCode}
addNtfToken st tknId tkn'
writeTBQueue pushQ (tkn', PNVerification regCode)
withNtfLog $ \s -> logUpdateToken s tknId token' regCode
pure NROk
TDEL -> do