Fix func and form variable naming in the Gallery assets.

This commit is contained in:
Colin Kuskie 2011-12-01 15:23:18 -08:00
parent 59d12c5c05
commit 97d9711118
2 changed files with 2 additions and 2 deletions

View file

@ -506,7 +506,7 @@ sub canEdit {
if ( $form->get('func') eq "add" && $form->get( 'className' )->isa( "WebGUI::Asset::Wobject::GalleryAlbum" ) ) {
return $self->canAddFile( $userId );
}
elsif ( $form->get('func') eq "editSave" && $form->get('assetId') eq "new" && $form->get( 'class' )->isa( 'WebGUI::Asset::Wobject::GalleryAlbum' ) ) {
elsif ( $form->get('func') eq "addSave" && $form->get('assetId') eq "new" && $form->get( 'className' )->isa( 'WebGUI::Asset::Wobject::GalleryAlbum' ) ) {
return $self->canAddFile( $userId );
}
else {

View file

@ -299,7 +299,7 @@ sub canEdit {
my $form = $self->session->form;
# Handle adding a photo
if ( $form->get("func") eq "add" || $form->get("func") eq "editSave" ) {
if ( $form->get("func") eq "add" || $form->get("func") eq "editSave" || $form->get("func") eq "addSave" ) {
return $self->canAddFile;
}
else {