Skip to content

Commit

Permalink
全角ハッシュタグ対応
Browse files Browse the repository at this point in the history
  • Loading branch information
sugyan committed Nov 18, 2009
1 parent 03d9a89 commit 038ca04
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion perl/bot.pl
Expand Up @@ -58,7 +58,7 @@
next if $status->{user}{screen_name} eq 'zenra_bot2';
next if $status->{user}{protected};
next if $text =~ / RT[ :] .* \@ \w+ /xms;
next if $text =~ / \#.+ /xms;
next if $text =~ / [\##]\w+ /xms;
next if $text =~ / 全裸で /xms;

my $zenrized = zenrize_all($text);
Expand Down
2 changes: 1 addition & 1 deletion python/zen-ra/bot/twitter.py
Expand Up @@ -202,7 +202,7 @@ def judge(status):
if re.search('RT[ :].*@\w+', status['text']):
return False
# ハッシュタグっぽいものを含んでいる発言も除く
if re.search('#\w+', status['text']):
if re.search(u'[##]\w+', status['text']):
return False
# 既に「全裸で」が含まれている発言も除く
if re.search(u'全裸で', status['text']):
Expand Down

0 comments on commit 038ca04

Please sign in to comment.