forked from sebsauvage/Shaarli
-
Notifications
You must be signed in to change notification settings - Fork 303
Open
Labels
Milestone
Description
Depends on #283
There is a usage caveat: the plugin only adds a link to the archived link on archive.org (yup, I'm aware it's the exact intended usage ^^)
Consequently, the following use case is broken:
- a link to
http://websi.teis archived- no one really cares about that particuliar site, thus it is never archived on archive.org
- the site goes down
- some time later, the Shaarli user attempts to retrieve the archive... which doesn't exist
Is it possible for a plugin to add
postAdd,postEdit,postDelete... hooks that would be called when a link is modified?In this case, this would mean:
- request the page from the archive.org cache
- it exists: that's a good start, maybe we can ask for it to be refreshed?
- it does not: ask for it to be added to the archive
This could be done through the JSON API or the Advanced Search form
It's possible because there is a save_link and delete_link hooks (called before the action though). It requires a bit of work though.