-
-
Notifications
You must be signed in to change notification settings - Fork 14
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
add moderation class, new cmd /moderation, and fix cmd output #50
Conversation
@@ -248,6 +252,7 @@ class CabalDetails extends EventEmitter { | |||
*/ | |||
addStatusMessage(message, channel=this.chname) { | |||
if (!this.channels[channel]) return | |||
debug(channel) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leftover debug output?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hehe oops :^)
@@ -43,6 +43,14 @@ module.exports = { | |||
}) | |||
} | |||
}, | |||
share: { | |||
help: () => 'print a cabal key with you as admin. useful for sending to friends', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Discussion point: do we want /share to share with you as admin, or with you + whoever is in your admin/mod-keys?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@noffle good discussion point! my reasoning was as follows:
what i reckoned was that it would get so absurdly long as to be useless if we shared all the admin + modkeys, which is why i opted for sharing oneself as an admin; reasoning that would have a similar effect
(at least that was what i was thinking at the time; given that the passed-in admin/modkeys don't actually issue admin/mods as statements then they won't be transitively be available)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey! I wasn't sure where to continue this convo :)
As I understand it, most people have one admin key. So a /share that used your admin keys should also just include one key, right? It feels like it might get confusing if inviting another user gives them a different moderation view than yours.
this pr moves some of the moderation commands from
commands.js
to a new class, and exposes a bunch of methods.the intent is for clients other than the terminal client to be able to easily use moderation commands. e.g. cabal desktop can tie menu actions to moderation commands more easily
details.moderation
, see moderation.js for the full listing atm/moderation
is a new command for showing moderation related commands/help
has been fixed by making use of monotonic timestampscommand
:details.on('command', ({ command, arg })