From: Mikael Nordfeldth Date: Tue, 15 Jul 2014 16:15:36 +0000 (+0200) Subject: Using empty on a function return value (thanks mrvdb) X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=55db74291c41fe901a20def7ddb6a93e23900458;p=quix0rs-gnu-social.git Using empty on a function return value (thanks mrvdb) Source: https://gist.github.com/mrvdb/0b49dd3c580bcfbe1358 --- diff --git a/actions/newnotice.php b/actions/newnotice.php index 81438502fa..3dab96daf3 100644 --- a/actions/newnotice.php +++ b/actions/newnotice.php @@ -69,7 +69,7 @@ class NewnoticeAction extends FormAction protected function doPreparation() { foreach(array('inreplyto') as $opt) { - if (!empty($this->trimmed($opt))) { + if ($this->trimmed($opt)) { $this->formOpts[$opt] = $this->trimmed($opt); } }