diff options
Diffstat (limited to 'lib/GridFiller/Chooser')
-rw-r--r-- | lib/GridFiller/Chooser/Random.pm | 2 | ||||
-rw-r--r-- | lib/GridFiller/Chooser/Smarter.pm | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/GridFiller/Chooser/Random.pm b/lib/GridFiller/Chooser/Random.pm index 7b86d55..7fefbf6 100644 --- a/lib/GridFiller/Chooser/Random.pm +++ b/lib/GridFiller/Chooser/Random.pm @@ -11,7 +11,7 @@ sub find_place_for { my $dir = int(rand(2)) ? $HORIZONTAL : $VERTICAL; - my $length = length $word; + my $length = $self->length->($word); my @ret; diff --git a/lib/GridFiller/Chooser/Smarter.pm b/lib/GridFiller/Chooser/Smarter.pm index 814e930..fd21dae 100644 --- a/lib/GridFiller/Chooser/Smarter.pm +++ b/lib/GridFiller/Chooser/Smarter.pm @@ -14,7 +14,7 @@ sub maxfirst { sub find_place_for { my ($self,$word) = @_; - my $length = length $word; + my $length = $self->length->($word); my @candidates; |