mirror of
https://github.com/silverstripe/silverstripe-reports
synced 2024-10-22 09:05:53 +00:00
add more strict condition inside getNewletterTypeEditForm to make NewsleterAdmin more robust.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@40816 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
48939b8102
commit
628105c410
@ -167,8 +167,8 @@ class NewsletterAdmin extends LeftAndMain {
|
||||
if(isset($mailType) && is_object($mailType) && $mailType->GroupID) {
|
||||
$group = DataObject::get_one("Group", "ID = $mailType->GroupID");
|
||||
}
|
||||
|
||||
if(isset($mailType)) {
|
||||
//The function could be called from CMS with $mailType isset but with empty string.
|
||||
if(isset($mailType)&&$mailType) {
|
||||
$fields = new FieldSet(
|
||||
new TextField("Title", "Newsletter Type"),
|
||||
new TextField("FromEmail", "Send newsletters from"),
|
||||
|
Loading…
x
Reference in New Issue
Block a user