diff options
Diffstat (limited to 'lib/lsg_irc/txt_plugin.ex')
-rw-r--r-- | lib/lsg_irc/txt_plugin.ex | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/lib/lsg_irc/txt_plugin.ex b/lib/lsg_irc/txt_plugin.ex index 93c4bb1..2c9dfca 100644 --- a/lib/lsg_irc/txt_plugin.ex +++ b/lib/lsg_irc/txt_plugin.ex @@ -168,9 +168,13 @@ defmodule LSG.IRC.TxtPlugin do result = with_stateful_results(msg, {:bang,"txt",msg.network,msg.channel,grep}, fn() -> Enum.reduce(state.triggers, [], fn({trigger, data}, acc) -> - Enum.reduce(data, acc, fn({l, _}, acc) -> - [{trigger, l} | acc] - end) + if !String.contains?(trigger, ".") do + Enum.reduce(data, acc, fn({l, _}, acc) -> + [{trigger, l} | acc] + end) + else + acc + end end) |> Enum.filter(fn({_, line}) -> line |