Commit c132a016 authored by Philipp Hörist's avatar Philipp Hörist
Browse files

Simplify isinstance check

parent 66575acf
Pipeline #9057 passed with stages
in 5 minutes and 4 seconds
......@@ -243,8 +243,7 @@ def process_event(self, event: TransferEventT) -> None:
elif isinstance(event, FileHashError):
self._ui.action_stack.set_visible_child_name('hash-error')
self._ui.transfer_action.set_text(_('File Verification Failed'))
elif (isinstance(event, FileRequestError) or
isinstance(event, FileSendError)):
elif isinstance(event, (FileRequestError, FileSendError)):
self._ui.action_stack.set_visible_child_name('error')
self._ui.transfer_action.set_text(_('File Transfer Cancelled'))
error_text = _('Connection with %s could not be '
......
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