File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -366,14 +366,15 @@ export class CloudSocialProvider {
366366 // TODO: typings for invite codes
367367 public inviteUser = ( clientId : string ) : Promise < Object > => {
368368 log . debug ( 'inviteUser' ) ;
369- if ( ! ( clientId in this . clients_ ) ) {
370- return Promise . reject ( new Error ( 'unknown client ' + clientId ) ) ;
369+ if ( ! ( clientId in this . savedContacts_ ) ) {
370+ return Promise . reject ( new Error ( 'unknown cloud instance ' + clientId ) ) ;
371371 }
372372 if ( this . savedContacts_ [ clientId ] . invite . user !== ADMIN_USERNAME ) {
373373 return Promise . reject ( new Error ( 'user is logged in as non-admin user ' +
374374 this . savedContacts_ [ clientId ] . invite . user ) ) ;
375375 }
376- return this . clients_ [ clientId ] . then ( ( connection : Connection ) => {
376+ return this . reconnect_ ( this . savedContacts_ [ clientId ] . invite ) . then (
377+ ( connection : Connection ) => {
377378 return connection . issueInvite ( ) ;
378379 } ) ;
379380 }
You can’t perform that action at this time.
0 commit comments