django-friendship icon indicating copy to clipboard operation
django-friendship copied to clipboard

Add an optional MAX_NUMBER_OF_FRIENDS_ALLOWED in settings

Open uri-rodberg opened this issue 6 years ago • 0 comments

In some websites the maximal number of friends is limited. You can add an optional MAX_NUMBER_OF_FRIENDS_ALLOWED in settings. If it's not defined then the number of friends is unlimited.

You can see for example on Speedy Net, where I defined MAX_NUMBER_OF_FRIENDS_ALLOWED = 800. I'm currently working on branch uri_merge_with_master_2018-12-28_a and you can see my latest code there:

https://github.com/speedy-net/speedy-net/tree/uri_merge_with_master_2018-12-28_a

(The code using this setting is mainly used in class LimitMaxFriendsMixin on https://github.com/speedy-net/speedy-net/blob/uri_merge_with_master_2018-12-28_a/speedy/core/friends/views.py).

Current (most up-to-date) links: https://github.com/speedy-net/speedy-net/tree/staging https://github.com/speedy-net/speedy-net/blob/staging/speedy/core/friends/views.py

uri-rodberg avatar Dec 29 '18 03:12 uri-rodberg