Comments (8)
Can it also delete a tweet again? :P
from jeeves.
It will only delete chat messages, but if you need / want drunk tweet protection I could probably implement something for !!tweet as well.
from jeeves.
Now that I think about it we probably want plugins to have an undo method which undos whatever it is it has done cc @DaveRandom
from jeeves.
I don't think it's worth implementing it for all plugins. Every plugin would have to keep state of their actions. For plugins that only fetch information and post messages, we could handle that at a higher level. Deleting tweets or something like that obviously needs its own implementation.
from jeeves.
@kelunik we can have it work for plugins like this maybe:
- user issues
!!undo <message link or id>
- fetch some info about the message (ID/content etc) and puts it into a VO.
- delete the message
- invoke
Plugin#onUndo($messageInfo): Promise
with a try/catch guard. Plugin may do any additional cleanup such as deleting a tweet, which it can figure out from the message info passed. A default implementation will be provided inBasePlugin
which is justreturn new Success;
from jeeves.
It would be sexy if !!giphy
does a move (to the gifbin) instead of a delete.
I'm annoying for bringing this up aren't I? :)
from jeeves.
@PeeHaa that could still work with a slight refactoring of the above, i.e. invoke Plugin#onUndo()
first and make the default action cancellable
from jeeves.
Implemented as !!remove.
Deleting tweets is a separate issue that as yet has not been needed.
from jeeves.
Related Issues (20)
- this is a test
- No feedback when stack exchange auth fails HOT 1
- !!horoscope doesn't work HOT 1
- Chat quotes formatting of !!tweet HOT 1
- RFC.PHP plugin doesn't respond if there's no RFCs HOT 2
- All I want for Christmas is a working comic plugin
- "comic reply" should be "comic rolleyes"
- Let !!comic resolve text from transcript links HOT 1
- Ignore @pings to self when someone posts a quote HOT 1
- Add wotd repin service HOT 1
- !!issue Broken - Request returns a 404.
- Request - (!!yomama / !!mama)
- "did you mean" plugin ? HOT 2
- Handle too long messages properly HOT 2
- wotd not displaying word correctly, provides link to dictionary.com HOT 6
- !!wotd Timeout
- Plugin - !!octoberfest / hacktoberfest
- status.github.com has been deprecated
- GitHub status HOT 1
- Feature request - a more general version of the php bugs plugin
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jeeves.