Show
Ignore:
Timestamp:
01/10/08 13:28:39 (7 years ago)
Author:
daisuke
Message:

lang/perl/Acme-Actors-JA; Avoid detecting false positives

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • lang/perl/Acme-Actors-JA/trunk/lib/Acme/Actors/JA/Scraper.pm

    r4347 r4348  
    108108 
    109109    $actor->{yomi} ||= $detail->{yomi_infobox} || $detail->{yomi_text}; 
     110 
    110111    if ($actor->{yomi}) { 
    111112        $actor->{yomi} =~ s/[ \s]+//g; 
     113        # Reject yomi if seemed to have gotten false positives 
     114        if ($actor->{yomi} !~ /^[\p{InKatakana}\p{InHiragana}]+$/) { 
     115            delete $actor->{yomi}; 
     116        } 
    112117    } 
    113118