You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, actually there's no way to limit the maximum number of mentions implemented in the framework. A suggestion I haven't tested yet, you could implement a custom mention processor and then override the find_mentionees_by_handles method. In there you can raise an error or slice the handles array.
def find_mentionees_by_handles(*handles)
handles = handles.slice(0, MAX_MENTIONS_COUNT)
User.where(username: handles)
end
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Is there a built-in method or any easy solution to add
max_mention_count
kinda functionality to prevent spam?Let's say someone mentioned 40 users but that's highly unlikely and probably will be done by a bot.
if there isn't any build-in method, where can I add that number limit before processing the mentions?
The text was updated successfully, but these errors were encountered: