Rebuild themes after stickying or locking post, so that catalog gets rebuilt
This commit is contained in:
parent
0439a9c6c5
commit
391f63e31f
|
@ -1099,6 +1099,8 @@ function mod_lock($board, $unlock, $post) {
|
||||||
modLog(($unlock ? 'Unlocked' : 'Locked') . " thread #{$post}");
|
modLog(($unlock ? 'Unlocked' : 'Locked') . " thread #{$post}");
|
||||||
buildThread($post);
|
buildThread($post);
|
||||||
buildIndex();
|
buildIndex();
|
||||||
|
// trigger themes
|
||||||
|
rebuildThemes('lock', $board);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($config['mod']['dismiss_reports_on_lock']) {
|
if ($config['mod']['dismiss_reports_on_lock']) {
|
||||||
|
@ -1133,6 +1135,8 @@ function mod_sticky($board, $unsticky, $post) {
|
||||||
modLog(($unsticky ? 'Unstickied' : 'Stickied') . " thread #{$post}");
|
modLog(($unsticky ? 'Unstickied' : 'Stickied') . " thread #{$post}");
|
||||||
buildThread($post);
|
buildThread($post);
|
||||||
buildIndex();
|
buildIndex();
|
||||||
|
// trigger themes
|
||||||
|
rebuildThemes('sticky', $board);
|
||||||
}
|
}
|
||||||
|
|
||||||
header('Location: ?/' . sprintf($config['board_path'], $board) . $config['file_index'], true, $config['redirect_http']);
|
header('Location: ?/' . sprintf($config['board_path'], $board) . $config['file_index'], true, $config['redirect_http']);
|
||||||
|
|
|
@ -26,7 +26,8 @@
|
||||||
$b->build($settings, $board);
|
$b->build($settings, $board);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} elseif ($action == 'post-thread' || ($settings['update_on_posts'] && $action == 'post') || ($settings['update_on_posts'] && $action == 'post-delete') && in_array($board, $boards)) {
|
} elseif ($action == 'post-thread' || ($settings['update_on_posts'] && $action == 'post') || ($settings['update_on_posts'] && $action == 'post-delete')
|
||||||
|
|| $action == 'sticky' || $action == 'lock' && in_array($board, $boards)) {
|
||||||
$b = new Catalog($settings);
|
$b = new Catalog($settings);
|
||||||
|
|
||||||
$action = generation_strategy("sb_catalog", array($board));
|
$action = generation_strategy("sb_catalog", array($board));
|
||||||
|
|
Loading…
Reference in New Issue