mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-23 19:44:20 +00:00
Change error message in TelegramCall.get_author
This commit is contained in:
parent
3ba75b2eb6
commit
818b504ec5
1 changed files with 2 additions and 2 deletions
|
@ -75,7 +75,7 @@ class TelegramBot:
|
|||
user: telegram.User = update.effective_user
|
||||
if user is None:
|
||||
if error_if_none:
|
||||
raise UnregisteredError("Author is not registered!")
|
||||
raise UnregisteredError("No author for this message")
|
||||
return None
|
||||
query = call.session.query(self.master_table)
|
||||
for link in self.identity_chain:
|
||||
|
@ -83,7 +83,7 @@ class TelegramBot:
|
|||
query = query.filter(self.identity_column == user.id)
|
||||
result = await asyncify(query.one_or_none)
|
||||
if result is None and error_if_none:
|
||||
raise UnregisteredError("Author is not registered!")
|
||||
raise UnregisteredError("Author is not registered")
|
||||
return result
|
||||
|
||||
self.TelegramCall = TelegramCall
|
||||
|
|
Loading…
Reference in a new issue