Skip to content

Commit

Permalink
simplify storable error-check
Browse files Browse the repository at this point in the history
  • Loading branch information
mohawk2 committed Feb 6, 2024
1 parent 3a90dce commit ca5df2c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions IO/Storable/storable.pd
Original file line number Diff line number Diff line change
Expand Up @@ -290,8 +290,7 @@ sub STORABLE_thaw {
# return if $cloning;
my $class = ref $pdl;
if (defined $hashref) {
croak "serial data with hashref!" unless !defined $serial ||
$serial eq "";
croak "serial data with hashref!" unless ($serial//'') eq "";
@$pdl{keys %$hashref} = values %$hashref;
} else {
# all the magic is happening in pdlunpack
Expand Down

0 comments on commit ca5df2c

Please sign in to comment.