From 60bb354a785b188c47b5b097b3c30ed9ce74e710 Mon Sep 17 00:00:00 2001 From: Yung Han Khoe Date: Sat, 12 Jul 2008 17:37:49 +0000 Subject: [PATCH] fixed: Gallery: Description Text appearing in Album --- docs/changelog/7.x.x.txt | 1 + lib/WebGUI/Asset/Wobject/GalleryAlbum.pm | 9 ++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/docs/changelog/7.x.x.txt b/docs/changelog/7.x.x.txt index 4c76a7315..4f948ff48 100644 --- a/docs/changelog/7.x.x.txt +++ b/docs/changelog/7.x.x.txt @@ -1,6 +1,7 @@ 7.5.17 - fixed: Payment Methods Hover Help Incomplete - fixed: Payment Method Titles Don't Match Buttons + - fixed: Gallery: Description Text appearing in Album 7.5.16 - Created a migration from 7.4.40 directly to 7.5.16. diff --git a/lib/WebGUI/Asset/Wobject/GalleryAlbum.pm b/lib/WebGUI/Asset/Wobject/GalleryAlbum.pm index d8d029113..94e18417f 100644 --- a/lib/WebGUI/Asset/Wobject/GalleryAlbum.pm +++ b/lib/WebGUI/Asset/Wobject/GalleryAlbum.pm @@ -492,7 +492,14 @@ sub getTemplateVars { my $gallery = $self->getParent; my $var = $self->get; my $owner = WebGUI::User->new( $session, $self->get("ownerUserId") ); - + + # Fix 'undef' vars since HTML::Template does inheritence on them + for my $key ( qw( description ) ) { + unless ( defined $var->{$key} ) { + $var->{ $key } = ''; + } + } + # Permissions $var->{ canAddFile } = $self->canAddFile; $var->{ canEdit } = $self->canEdit;