made more changes to messenger.py