- fix [ 1240324 ] Folder.pm error evaluating $isImage
This commit is contained in:
parent
25391c83c0
commit
dcfa6156d1
1 changed files with 3 additions and 3 deletions
|
|
@ -124,7 +124,7 @@ sub view {
|
|||
my $children = $self->getLineage( ["children"], { returnObjects=>1 });
|
||||
my %vars;
|
||||
foreach my $child (@{$children}) {
|
||||
if (ref $child eq "WebGUI::Asset::Wobject::Folder") {
|
||||
if (ref($child) eq "WebGUI::Asset::Wobject::Folder") {
|
||||
push(@{$vars{"subfolder_loop"}}, {
|
||||
id => $child->getId,
|
||||
url => $child->getUrl,
|
||||
|
|
@ -133,9 +133,9 @@ sub view {
|
|||
"icon.big"=>$child->getIcon
|
||||
});
|
||||
} else {
|
||||
my $isImage = (ref $child =~ /^WebGUI::Asset::File::Image/);
|
||||
my $isImage = (ref($child) =~ /^WebGUI::Asset::File::Image/);
|
||||
my $thumbnail = $child->getThumbnailUrl if ($isImage);
|
||||
my $isFile = (ref $child =~ /^WebGUI::Asset::File/);
|
||||
my $isFile = (ref($child) =~ /^WebGUI::Asset::File/);
|
||||
my $file = $child->getFileUrl if ($isFile);
|
||||
push(@{$vars{"file_loop"}},{
|
||||
id=>$child->getId,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue