Skip to content
This repository has been archived by the owner on Jun 13, 2020. It is now read-only.

Added support for anchor threads. #296

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Added support for anchor threads. #296

wants to merge 1 commit into from

Conversation

ghost
Copy link

@ghost ghost commented Dec 8, 2014

Anchor threads act similar to Sticky threads, with the exception of staying at the top of the board.
( See #270 )
Here's some code that should programatically update the database to support anchor threads.
https://gist.github.com/forklessanon/319076e8c880bdf44d10
The install.sql has the updated query data in the commit.

@ctrlcctrlv
Copy link
Owner

Not sure I get it - this adds two tiers of stickies, yes? @czaks is this worth adding an extra column to all tables in your opinion? Would you merge this upstream?

@ghost
Copy link
Author

ghost commented Dec 19, 2014

A sticky thread acts as it does now, sticking at the top of the index, but falls to the bottom of the catalog but takes priority over regular threads when it comes to pruning.
An anchor thread is similar to a standard thread except that it has higher priority than a standard thread when it comes to pruning.

When the board gets "cleaned" for thread pruning, threads are sorted for stickies first, then for anchor threads, then regular posts, and that ordered set of posts are counted to figure out what to prune off.

If there was a way to mark a thread as "avoid pruning" without adding a DB column and without making it an actual sticky at the top of the index, I'd be more than willing to make it work. I have yet to think of such a solution.

@ghost
Copy link
Author

ghost commented Jan 29, 2015

CC: @czaks - thoughts?

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

Successfully merging this pull request may close these issues.

1 participant