Skip to content

Commit

Permalink
Ignore keyword patterns
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Jan 29, 2024
1 parent c231cec commit b53ee10
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/Cavil/Command/learn.pm
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,10 @@ sub _output_patterns ($self, $good, $bad) {

my $count = my $last_id = 0;
while (1) {
my $batch = $db->query('SELECT id, pattern FROM license_patterns WHERE id > ? ORDER BY id ASC LIMIT 100', $last_id);
my $batch = $db->query(
q{SELECT id, pattern FROM license_patterns
WHERE license != '' AND id > ? ORDER BY id ASC LIMIT 100}, $last_id
);
last if $batch->rows == 0;

for my $hash ($batch->hashes->each) {
Expand Down

0 comments on commit b53ee10

Please sign in to comment.