Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds concept of New Followers where they are NOT in the past known #3

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

coolacid
Copy link

@coolacid coolacid commented Mar 5, 2016

There are times where a spammer will attempt to unfollow, and refollow to get their name mentioned multiple times.

This PR stores stores the last followers in a replicant array and checks to see if the follower is NOT in that array. If it is not, triggers a new message "newFollower".

I'm concerned that if the array gets too big it will slow down drastically, but this is a good start.

@coolacid
Copy link
Author

coolacid commented Mar 5, 2016

FTR: I was finally able to get to test this. I unfollowed a channel, waited for my name to drop from the follower list, then refollowed. I got the "follower" message, but not the "newFollower" message.

Also, I'm toying with the idea of capping the array to say 1,000. Something like:

if (array.length > 1000) array.length = 1000

Much like: http://jsfiddle.net/orolo/wJDXL/

@coolacid
Copy link
Author

ping :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant