mirror of
https://github.com/pragma-/pbot.git
synced 2024-12-23 19:22:40 +01:00
strictnamespace is now more strict
This commit is contained in:
parent
520cce7ea8
commit
4b76dbf237
@ -1097,12 +1097,14 @@ sub interpreter {
|
||||
my @chanlist = ();
|
||||
my ($fwd_chan, $fwd_trig);
|
||||
|
||||
# build list of which channels contain the keyword, keeping track of the last one and count
|
||||
foreach my $factoid ($self->{factoids}->get_all("index2 = $original_keyword", 'index1', 'type')) {
|
||||
next if $factoid->{type} ne 'text' and $factoid->{type} ne 'module';
|
||||
push @chanlist, $self->{factoids}->get_data($factoid->{index1}, '_name');
|
||||
$fwd_chan = $factoid->{index1};
|
||||
$fwd_trig = $original_keyword;
|
||||
unless ($strictnamespace) {
|
||||
# build list of which channels contain the keyword, keeping track of the last one and count
|
||||
foreach my $factoid ($self->{factoids}->get_all("index2 = $original_keyword", 'index1', 'type')) {
|
||||
next if $factoid->{type} ne 'text' and $factoid->{type} ne 'module';
|
||||
push @chanlist, $self->{factoids}->get_data($factoid->{index1}, '_name');
|
||||
$fwd_chan = $factoid->{index1};
|
||||
$fwd_trig = $original_keyword;
|
||||
}
|
||||
}
|
||||
|
||||
my $ref_from = $context->{ref_from} ? "[$context->{ref_from}] " : "";
|
||||
|
Loading…
Reference in New Issue
Block a user