File tree Expand file tree Collapse file tree 1 file changed +16
-17
lines changed
frontend/iframe/viewmodels Expand file tree Collapse file tree 1 file changed +16
-17
lines changed Original file line number Diff line number Diff line change @@ -165,27 +165,26 @@ export class RootViewModel extends ViewModel<SegmentType, Options> {
165165 this . _showLogin ( loginToken ) ;
166166 }
167167 } else {
168- if ( this . _singleRoomIdOrAlias ) {
169- // No active session but we're in single-room mode.
170- if ( ! this . _resolvedSingleRoomId ) {
171- try {
172- this . _resolvedSingleRoomId = await this . resolveRoomAlias ( this . _singleRoomIdOrAlias ) ;
173- } catch ( error ) {
174- console . warn ( error ) ;
175- }
176- }
177-
178- if ( this . _resolvedSingleRoomId ) {
179- await this . _showUnknownRoom ( this . _resolvedSingleRoomId ) ;
180- return ;
181- }
182- }
183-
184168 try {
185169 if ( ! ( shouldRestoreLastUrl && this . urlRouter . tryRestoreLastUrl ( ) ) ) {
186170 const sessionInfos = await this . platform . sessionInfoStorage . getAll ( ) ;
187171 if ( sessionInfos . length === 0 ) {
188- this . navigation . push ( Section . Login ) ;
172+ if ( this . _singleRoomIdOrAlias ) {
173+ // No active session but we're in single-room mode.
174+ if ( ! this . _resolvedSingleRoomId ) {
175+ try {
176+ this . _resolvedSingleRoomId = await this . resolveRoomAlias ( this . _singleRoomIdOrAlias ) ;
177+ } catch ( error ) {
178+ console . warn ( error ) ;
179+ }
180+ }
181+
182+ if ( this . _resolvedSingleRoomId ) {
183+ await this . _showUnknownRoom ( this . _resolvedSingleRoomId ) ;
184+ }
185+ } else {
186+ this . navigation . push ( Section . Login ) ;
187+ }
189188 } else if ( sessionInfos . length === 1 ) {
190189 this . navigation . push ( Section . Session , sessionInfos [ 0 ] . id ) ;
191190 } else {
You can’t perform that action at this time.
0 commit comments