mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-09 05:52:41 +00:00
fix: don't allow users to start chats with themselves
This commit is contained in:
parent
6f138f2d44
commit
85f18057ae
@ -15,6 +15,8 @@ ModalPopup {
|
|||||||
if (!Utils.isChatKey(chatKey.text) && !Utils.isValidETHNamePrefix(chatKey.text)) {
|
if (!Utils.isChatKey(chatKey.text) && !Utils.isValidETHNamePrefix(chatKey.text)) {
|
||||||
validationError = "This needs to be a valid chat key or ENS username";
|
validationError = "This needs to be a valid chat key or ENS username";
|
||||||
ensUsername.text = "";
|
ensUsername.text = "";
|
||||||
|
} else if (profileModel.profile.pubKey === chatKey.text) {
|
||||||
|
validationError = qsTr("Can't chat with yourself");
|
||||||
} else {
|
} else {
|
||||||
validationError = ""
|
validationError = ""
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user