Clone stopped working in several tests in 5.14.2. Remove it in favor of Storable::dclone.
Clone handles being passed scalar data, but dclone does not.
This commit is contained in:
parent
1b4f7c33fa
commit
be37f12ab1
23 changed files with 70 additions and 49 deletions
|
|
@ -20,7 +20,7 @@ use strict;
|
|||
use Class::InsideOut qw(readonly private id register);
|
||||
use JSON;
|
||||
use Tie::IxHash;
|
||||
use Clone qw/clone/;
|
||||
use Storable qw/dclone/;
|
||||
use WebGUI::DateTime;
|
||||
use WebGUI::Exception;
|
||||
use WebGUI::Utility;
|
||||
|
|
@ -579,11 +579,16 @@ sub get {
|
|||
|
||||
# return a specific property
|
||||
if (defined $name) {
|
||||
return clone $objectData{id $self}{$name};
|
||||
if (ref $objectData{id $self}{$name}) {
|
||||
return dclone $objectData{id $self}{$name};
|
||||
}
|
||||
else {
|
||||
return $objectData{id $self}{$name};
|
||||
}
|
||||
}
|
||||
|
||||
# return a copy of all properties
|
||||
return clone $objectData{id $self};
|
||||
return dclone $objectData{id $self};
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue