Fixed #82061 by listening to the loginstatechanged event.