feeds.py 482 B

12345678910111213141516171819202122232425
  1. def follow(follower=None, followee=None):
  2. """
  3. :param follower: The actor that followed
  4. :type follower: dict
  5. :param followee: The actor being followed
  6. :type followee: dict
  7. """
  8. return {
  9. 'type': 'follow',
  10. 'follower': {
  11. 'name': follower['name'],
  12. 'id': follower['id']
  13. },
  14. 'followee': {
  15. 'name': followee['name'],
  16. 'id': followee['id']
  17. },
  18. }