diff options
-rw-r--r-- | lib/App/Glacier/DB.pm | 2 | ||||
-rw-r--r-- | lib/App/Glacier/Progress.pm | 7 |
2 files changed, 6 insertions, 3 deletions
diff --git a/lib/App/Glacier/DB.pm b/lib/App/Glacier/DB.pm index 74ad665..ad165f0 100644 --- a/lib/App/Glacier/DB.pm +++ b/lib/App/Glacier/DB.pm @@ -22,3 +22,3 @@ my %transcode = ( # Encoder - sub { JSON->new->convert_blessed(1)->encode(shift) }, + sub { JSON->new->allow_nonref->convert_blessed(1)->encode(shift) }, # Decoder diff --git a/lib/App/Glacier/Progress.pm b/lib/App/Glacier/Progress.pm index 39b892b..8defc7d 100644 --- a/lib/App/Glacier/Progress.pm +++ b/lib/App/Glacier/Progress.pm @@ -121,4 +121,7 @@ sub display { } - - $text .= ' ' x ($self->_getwidth - length($text)); + + my $pad = $self->_getwidth - length($text); + if ($pad > 0) { + $text .= ' ' x $pad; + } my $fd = $self->{_tty}; |