Philipp Hörist pushed to branch master at gajim / gajim
Commits:
e9b33475 by Philipp Hörist at 2023-11-06T11:05:49+01:00
new: Application: Make sure no account without username is created
- - - - -
1 changed file:
- gajim/common/application.py
Changes:
=====================================
gajim/common/application.py
=====================================
@@ -337,7 +337,7 @@ def _on_update_response(self, request: HTTPRequest) -> None:
def create_account(self,
account: str,
- username: str,
+ username: str | None,
domain: str,
password: str,
proxy_name: str | None,
@@ -347,10 +347,13 @@ def create_account(self,
anonymous: bool = False
) -> None:
- account_label = f'{username}@{domain}'
if anonymous:
username = 'anon'
- account_label = f'anon@{domain}'
+
+ if not username:
+ raise ValueError('Username must be set')
+
+ account_label = f'{username}@{domain}'
config: dict[str, str | int | bool] = {
'name': username,
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/e9b334752c2e6a864e3214d955c7e62bb3f91e11
--
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/e9b334752c2e6a864e3214d955c7e62bb3f91e11
You're receiving this email because of your account on dev.gajim.org.
_______________________________________________
Commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]