Don't add space if there's no string in new notice content
This commit is contained in:
parent
03d2b680f8
commit
a47563cf3d
|
@ -104,7 +104,7 @@ class NewnoticeAction extends FormAction
|
|||
// throws exception on failure
|
||||
$upload = MediaFile::fromUpload('attach', $this->scoped);
|
||||
if (Event::handle('StartSaveNewNoticeAppendAttachment', array($this, $upload, &$content, &$options))) {
|
||||
$content .= ' ' . $upload->shortUrl();
|
||||
$content = ($content==='' ? '' : ' ') . $upload->shortUrl();
|
||||
}
|
||||
Event::handle('EndSaveNewNoticeAppendAttachment', array($this, $upload, &$content, &$options));
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user