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

Karma-ing multiple people simultaneously #11

Conversation

diachini
Copy link

Description

This is a really ridiculously naive approach to handle this... There are 2 commits: 1 breaking out the parsing of the karma to a method, and the 2nd using recursion with that method to remove the first found "++"'ed or "--"'ed user/item from the message and see if there are any others.

Why we probably don't actually wanna do this

(node:92134) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 loaded listeners added. Use emitter.setMaxListeners() to increase limit

(I want to look into what is increasing the listener counts.. I'm assuming it's the passing of robot into doKarma instead of initializing a ParseKarma with the robot...)

QA Steps

  • thing1++ and also thing2++
  • confirm output:
    thing1 has 1 point
    thing2 has 1 point
    

Related Issue

closes #10

diachini added 2 commits February 10, 2019 16:21
In order to parse karma for > 1 user at a time, we're going to need to
be able to call a function doing the same thing over with a subset of
the message.

re: jetpackworkflow#10
If you have the message "@person1++ @Person2++ @person3-- @person4--",
this will recursively add/remove karma to each of the people karma'ed.

closes jetpackworkflow#10
@diachini
Copy link
Author

See #13 instead! 🎉

@diachini diachini closed this May 11, 2020
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.

Allow 2 (or more) users to receive karma in a single message
1 participant