472
472
if (mAutoRequest) {
473
// if there is any remaining account, request to start chatting using the account
474
Q_FOREACH(AccountEntry *account, accounts) {
475
ChatManager::instance()->startChat(account->accountId(), properties);
473
// if the chat type is room we should only request the channel to the desired account.
474
if (chatType() == ChatTypeRoom) {
475
AccountEntry *account = TelepathyHelper::instance()->accountForId(mAccountId);
476
if (account && accounts.contains(account)) {
477
ChatManager::instance()->startChat(account->accountId(), properties);
480
// if there is any remaining account, request to start chatting using the account
481
Q_FOREACH(AccountEntry *account, accounts) {
482
ChatManager::instance()->startChat(account->accountId(), properties);