X-Git-Url: http://git.shiar.net/minimedit.git/blobdiff_plain/2d7b510a9d33a552b024e1db00212658f21afce6..ecfc420d52ce7983a6361ccc7dec24fd46ec2d07:/upload.inc.php diff --git a/upload.inc.php b/upload.inc.php index 77fa846..f2e101a 100644 --- a/upload.inc.php +++ b/upload.inc.php @@ -84,9 +84,6 @@ function createcomment($input, &$Issue = NULL) $reply['raw'] = $body; $reply['message'] = messagehtml($body); } - if (isset($input['announce'])) { - $reply['announced'] = !!$input['announce']; - } if ($_FILES and !empty($_FILES['image'])) { $target = 'data/upload'; if (!file_exists($target)) { @@ -107,6 +104,12 @@ function createcomment($input, &$Issue = NULL) } } } + if (!$reply) { + throw new Exception("lege inhoud"); + } + if (isset($input['announce'])) { + $reply['announced'] = !!$input['announce']; + } if (isset($input['id'])) { $newcomment = $input['id'];