diff options
| author | Jules Laplace <carbon@melanarchy.org> | 2014-09-26 13:03:59 -0500 |
|---|---|---|
| committer | Jules Laplace <carbon@melanarchy.org> | 2014-09-26 13:03:59 -0500 |
| commit | 2f4aebe8139faff0e6456676fd83bf5c0e4e3c4d (patch) | |
| tree | 7f0df489ce253c53a2cc5b5148619c31441b6072 /bucky2 | |
| parent | 30f1cd22906cae2bd4df35b4bf8fd72287f73ac5 (diff) | |
edit move-comment scripts; search indexes private threads (shrug)
Diffstat (limited to 'bucky2')
| -rwxr-xr-x | bucky2/bin/move-comment | 6 | ||||
| -rwxr-xr-x | bucky2/bin/move-file | 6 | ||||
| -rw-r--r-- | bucky2/lib/Bucky/Search.pm | 2 |
3 files changed, 7 insertions, 7 deletions
diff --git a/bucky2/bin/move-comment b/bucky2/bin/move-comment index 29c59ef..7723447 100755 --- a/bucky2/bin/move-comment +++ b/bucky2/bin/move-comment @@ -4,15 +4,15 @@ use lib "../lib"; use Bucky; if (scalar(@ARGV) < 2) { - print "usage: move-comment id thread\n"; + print "usage: move-comment thread-id comment-id\n"; exit(1); } my $bucky = new Bucky; $bucky->db->update_by_id('comment', { - "id" => $ARGV[0], + "id" => $ARGV[1], "record" => { - "thread" => $ARGV[1] + "thread" => $ARGV[0] } }); diff --git a/bucky2/bin/move-file b/bucky2/bin/move-file index 7c9e603..bd6dc48 100755 --- a/bucky2/bin/move-file +++ b/bucky2/bin/move-file @@ -4,15 +4,15 @@ use lib "../lib"; use Bucky; if (scalar(@ARGV) < 2) { - print "usage: move-file id thread\n"; + print "usage: move-file thread-id comment-id\n"; exit(1); } my $bucky = new Bucky; $bucky->db->update_by_id('file', { - "id" => $ARGV[0], + "id" => $ARGV[1], "record" => { - "thread" => $ARGV[1] + "thread" => $ARGV[0] } }); diff --git a/bucky2/lib/Bucky/Search.pm b/bucky2/lib/Bucky/Search.pm index 43c23f7..8759dad 100644 --- a/bucky2/lib/Bucky/Search.pm +++ b/bucky2/lib/Bucky/Search.pm @@ -244,7 +244,7 @@ sub search next if $i++ < $start; my $thread = $self->thread( $match->{'thread'} ); next unless $thread; - next if $thread->{'private'}; + # next if $thread->{'private'}; last if $to_display-- == 0; push @$results, $match; push @$comments_to_get, $match->{'comment'} if $match->{'comment'}; |
