Permalink
Browse files

Merge pull request #54 from warthurton/master

Fixes issue #41
  • Loading branch information...
2 parents f318b77 + aac345a commit 0a0d8bafcb46542eb67a6dab158f7c553e72deb5 @warthurton warthurton committed Mar 15, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/DDG/Goodie/Dice.pm
@@ -24,7 +24,7 @@ handle remainder => sub {
}
return join(' ', @output) if @output;
}
- elsif ($_ =~ /^(\d{0,2})[d|w](\d+)\s?([+-])?\s?(\d+|[lh])?$/) { # 'w' is the German form
+ elsif ($_ =~ /^(\d{0,4})[d|w](\d+)\s?([+-])?\s?(\d+|[lh])?$/) { # 'w' is the German form
my $output;
my $number_of_dice = $1 || 1;
my $number_of_faces = $2;
@@ -42,7 +42,7 @@ handle remainder => sub {
} else {
push(@rolls, -(pop(@rolls)));
}
- } elsif ($3 eq '+' && ($4 eq 'l' || $4 eq 'h')) {
+ } elsif ($3 eq '+' && ($4 eq 'l' || $4 eq 'h')) {
return;
} else {
push(@rolls, int("$3$4"));

0 comments on commit 0a0d8ba

Please sign in to comment.