core (XMPP): sendMessage refactoring:

- better separation of message sending actions
    - use of more generic exceptions to hook the behaviour (SkipHistory and CancelError)
    - use of raise instead of return
    - use of failure.trap
This commit is contained in:
Goffi 2014-06-07 16:35:29 +02:00
commit 87b3e413ee
4 changed files with 74 additions and 71 deletions

View file

@ -92,3 +92,6 @@ class DatabaseError(Exception):
class PasswordError(Exception):
pass
class SkipHistory(Exception): # used in MessageReceivedTrigger to avoid history writting
pass