@@ -151,7 +151,7 @@ |
||
| 151 | 151 | return; |
| 152 | 152 | } |
| 153 | 153 | foreach ($parameters as $param_data) { |
| 154 | - if ( empty($param_data['domain']) |
|
| 154 | + if (empty($param_data['domain']) |
|
| 155 | 155 | || empty($param_data['name']) |
| 156 | 156 | || empty($param_data['value'])) { |
| 157 | 157 | // TODO: Log warning |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | } |
| 59 | 59 | |
| 60 | 60 | //Substyle handling |
| 61 | - if ( !empty($data['message_array']['substyle']) |
|
| 61 | + if (!empty($data['message_array']['substyle']) |
|
| 62 | 62 | && !preg_match('/^builtin:/', $data['message_array']['substyle'])) { |
| 63 | 63 | debug_add("Appending substyle {$data['message_array']['substyle']}"); |
| 64 | 64 | midcom::get()->style->append_substyle($data['message_array']['substyle']); |
@@ -117,7 +117,7 @@ discard block |
||
| 117 | 117 | private function _real_show_compose($handler_id, array &$data) |
| 118 | 118 | { |
| 119 | 119 | $prefix = ''; |
| 120 | - if ( !empty($data['message_array']['substyle']) |
|
| 120 | + if (!empty($data['message_array']['substyle']) |
|
| 121 | 121 | && preg_match('/^builtin:(.*)/', $data['message_array']['substyle'], $matches_style)) { |
| 122 | 122 | $prefix = $matches_style[1] . '-'; |
| 123 | 123 | } |
@@ -24,7 +24,7 @@ |
||
| 24 | 24 | if (!$this->timestamp) { |
| 25 | 25 | $this->timestamp = time(); |
| 26 | 26 | } |
| 27 | - if ( !$this->referrer |
|
| 27 | + if (!$this->referrer |
|
| 28 | 28 | && !empty($_SERVER['HTTP_REFERER'])) { |
| 29 | 29 | $this->referrer = $_SERVER['HTTP_REFERER']; |
| 30 | 30 | } |
@@ -34,7 +34,7 @@ |
||
| 34 | 34 | echo " <th>{$type}</th>\n"; |
| 35 | 35 | echo " <td style=\"text-align: right;\">" . number_format($count) . "</td>\n"; |
| 36 | 36 | if (isset($cleanups_kept[$type])) { |
| 37 | - echo " <td style=\"text-align: right;\">" . number_format($cleanups_kept[$type]) ."</td>\n"; |
|
| 37 | + echo " <td style=\"text-align: right;\">" . number_format($cleanups_kept[$type]) . "</td>\n"; |
|
| 38 | 38 | } |
| 39 | 39 | echo " </tr>\n"; |
| 40 | 40 | } |
@@ -73,7 +73,7 @@ |
||
| 73 | 73 | $button_config[MIDCOM_TOOLBAR_URL] = $url; |
| 74 | 74 | //The constants are numeric, so array_merge won't work... |
| 75 | 75 | foreach ($options as $key => $value) { |
| 76 | - if ( is_array($value) |
|
| 76 | + if (is_array($value) |
|
| 77 | 77 | && !empty($button_config[$key])) { |
| 78 | 78 | $value = array_merge($button_config[$key], $value); |
| 79 | 79 | } |
@@ -12,7 +12,7 @@ |
||
| 12 | 12 | { |
| 13 | 13 | public function validate($value, Constraint $constraint) |
| 14 | 14 | { |
| 15 | - if ( empty($value['archival']) |
|
| 15 | + if (empty($value['archival']) |
|
| 16 | 16 | && empty($value['file'])) { |
| 17 | 17 | $this->context->buildViolation($constraint->message) |
| 18 | 18 | ->addViolation(); |
@@ -1,7 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | midcom::get()->auth->require_admin_user(); |
| 3 | 3 | |
| 4 | -if ( empty($_POST['to']) |
|
| 4 | +if (empty($_POST['to']) |
|
| 5 | 5 | || empty($_POST['from'])) { |
| 6 | 6 | ?> |
| 7 | 7 | <h2>Send test email</h2> |
@@ -104,7 +104,7 @@ discard block |
||
| 104 | 104 | if (file_exists(MIDCOM_STATIC_ROOT . $jqgrid_path . 'i18n/grid.locale-' . $language . '.js')) { |
| 105 | 105 | $lang = $language; |
| 106 | 106 | } |
| 107 | - $head->add_jsfile(MIDCOM_STATIC_URL . $jqgrid_path . 'i18n/grid.locale-'. $lang . '.js'); |
|
| 107 | + $head->add_jsfile(MIDCOM_STATIC_URL . $jqgrid_path . 'i18n/grid.locale-' . $lang . '.js'); |
|
| 108 | 108 | $head->add_jsfile(MIDCOM_STATIC_URL . $jqgrid_path . 'jquery.jqgrid.min.js'); |
| 109 | 109 | |
| 110 | 110 | org_openpsa_widgets_ui::add_head_elements(); |
@@ -159,7 +159,7 @@ discard block |
||
| 159 | 159 | public function set_option($key, $value, $autoquote_string = true) |
| 160 | 160 | { |
| 161 | 161 | $this->_raw_options[$key] = $value; |
| 162 | - if ( $autoquote_string |
|
| 162 | + if ($autoquote_string |
|
| 163 | 163 | && is_string($value)) { |
| 164 | 164 | $value = '"' . str_replace('"', '\\"', $value) . '"'; |
| 165 | 165 | } elseif ($value === true) { |
@@ -192,7 +192,7 @@ discard block |
||
| 192 | 192 | public function set_select_column($name, $label, $options, array $selectdata) |
| 193 | 193 | { |
| 194 | 194 | $selectstring = implode(';', array_map( |
| 195 | - function ($key, $value) { |
|
| 195 | + function($key, $value) { |
|
| 196 | 196 | return $key . ':' . $value; |
| 197 | 197 | }, |
| 198 | 198 | array_keys($selectdata), |
@@ -243,7 +243,7 @@ discard block |
||
| 243 | 243 | */ |
| 244 | 244 | public function remove_column($name) |
| 245 | 245 | { |
| 246 | - if ( empty($name) |
|
| 246 | + if (empty($name) |
|
| 247 | 247 | || !array_key_exists($name, $this->_columns)) { |
| 248 | 248 | throw new midcom_error('Invalid column name ' . $name); |
| 249 | 249 | } |
@@ -23,7 +23,7 @@ |
||
| 23 | 23 | include dirname(__DIR__) . '/config-default.inc.php'; |
| 24 | 24 | } |
| 25 | 25 | |
| 26 | -if (! defined('MIDCOM_STATIC_URL')) { |
|
| 26 | +if (!defined('MIDCOM_STATIC_URL')) { |
|
| 27 | 27 | define('MIDCOM_STATIC_URL', '/midcom-static'); |
| 28 | 28 | } |
| 29 | 29 | |