diff --git a/src/components/appSelectPeers.ts b/src/components/appSelectPeers.ts index 817a21bb..8cf85a6e 100644 --- a/src/components/appSelectPeers.ts +++ b/src/components/appSelectPeers.ts @@ -478,7 +478,7 @@ export default class AppSelectPeers { div.dataset.key = '' + peerId; if(typeof(peerId) === 'number') { if(title === undefined) { - title = new PeerTitle({peerId, onlyFirstName: true}).element; + title = new PeerTitle({peerId, onlyFirstName: true, dialog: true}).element; } avatarEl.setAttribute('peer', '' + peerId); diff --git a/src/components/sidebarLeft/tabs/editProfile.ts b/src/components/sidebarLeft/tabs/editProfile.ts index b13af631..6e0d9f85 100644 --- a/src/components/sidebarLeft/tabs/editProfile.ts +++ b/src/components/sidebarLeft/tabs/editProfile.ts @@ -135,7 +135,7 @@ export default class AppEditProfileTab extends SliderSuperTab { })); } - if(this.usernameInputField.isValid() && this.usernameInputField.input.classList.contains('valid')) { + if(this.usernameInputField.isValid() && !this.usernameInputField.input.classList.contains('error')) { promises.push(appUsersManager.updateUsername(this.usernameInputField.value)); }