Commit b5a024f1 authored by Philipp Hörist's avatar Philipp Hörist

GroupchatCreation: Use MUC_DISCO_ERRORS

parent 84f3c023
......@@ -24,6 +24,7 @@ from nbxmpp.util import is_error_result
from gajim.common import app
from gajim.common.const import MUC_CREATION_EXAMPLES
from gajim.common.const import MUC_DISCO_ERRORS
from gajim.common.i18n import _
from gajim.gtk.dialogs import ErrorDialog
......@@ -48,16 +49,6 @@ class CreateGroupchatWindow(Gtk.ApplicationWindow):
self._destroyed = False
not_muc_error = _('Address does not belong to a group chat server')
self._error_messages = {
'remote-server-not-found': _('Remote server not found'),
'remote-server-timeout': _('Remote server timeout'),
'service-unavailable': not_muc_error,
'subscription-required': not_muc_error,
'not-muc-service': not_muc_error,
'already-exists': _('Group chat already exists')
self._account = self._fill_account_combo(account)
......@@ -168,11 +159,11 @@ class CreateGroupchatWindow(Gtk.ApplicationWindow):
def _set_warning_from_error(self, error):
text = self._error_messages.get(error.type, str(error))
text = MUC_DISCO_ERRORS.get(error.type, str(error))
def _set_warning_from_error_code(self, error_code):
def _on_address_entry_changed(self, entry):
text = entry.get_text()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment