@@ -46,7 +46,7 @@ |
||
46 | 46 | } |
47 | 47 | } |
48 | 48 | |
49 | - if ( !$request->request->has('midcom_services_auth_frontend_form_submit') |
|
49 | + if (!$request->request->has('midcom_services_auth_frontend_form_submit') |
|
50 | 50 | || !$request->request->has('username') |
51 | 51 | || !$request->request->has('password')) { |
52 | 52 | return null; |
@@ -181,7 +181,8 @@ |
||
181 | 181 | if ($this->_response === null) { |
182 | 182 | $this->_stop('Could not handle request, unknown method', Response::HTTP_METHOD_NOT_ALLOWED); |
183 | 183 | } |
184 | - } catch (midcom_error $e) { |
|
184 | + } |
|
185 | + catch (midcom_error $e) { |
|
185 | 186 | $this->_responseStatus = $e->getCode(); |
186 | 187 | return $this->_send_response($e->getMessage()); |
187 | 188 | } |
@@ -4,7 +4,7 @@ |
||
4 | 4 | midcom::get()->auth->require_admin_user(); |
5 | 5 | $post = Request::createFromGlobals()->request; |
6 | 6 | |
7 | -if ( !$post->get('to') |
|
7 | +if (!$post->get('to') |
|
8 | 8 | || !$post->get('from')) { |
9 | 9 | ?> |
10 | 10 | <h2>Send test email</h2> |
@@ -1,9 +1,9 @@ |
||
1 | 1 | <div class="area org_openpsa_helper_box"> |
2 | -<h3><?php echo $data['l10n']->get('folders');?></h3> |
|
2 | +<h3><?php echo $data['l10n']->get('folders'); ?></h3> |
|
3 | 3 | <?php |
4 | 4 | $nap = new midcom_helper_nav(); |
5 | 5 | $current_node = $nap->get_node($nap->get_current_node()); |
6 | 6 | $url = $current_node[MIDCOM_NAV_RELATIVEURL]; |
7 | -midcom::get()->dynamic_load($url. "directory/navigation/"); |
|
7 | +midcom::get()->dynamic_load($url . "directory/navigation/"); |
|
8 | 8 | ?> |
9 | 9 | </div> |
10 | 10 | \ No newline at end of file |
@@ -4,7 +4,7 @@ |
||
4 | 4 | midcom::get()->auth->require_admin_user(); |
5 | 5 | $post = Request::createFromGlobals()->request; |
6 | 6 | |
7 | -if ( !$post->get('to') |
|
7 | +if (!$post->get('to') |
|
8 | 8 | || !$post->get('from')) { |
9 | 9 | ?> |
10 | 10 | <h2>Send test email</h2> |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | { |
63 | 63 | $entries = array_merge($this->get_status_entries(), $this->get_journal_entries()); |
64 | 64 | |
65 | - usort($entries, function (array $a, array $b) { |
|
65 | + usort($entries, function(array $a, array $b) { |
|
66 | 66 | if ($a['timestamp'] == $b['timestamp']) { |
67 | 67 | return $b['order'] <=> $a['order']; |
68 | 68 | } |
@@ -92,8 +92,8 @@ discard block |
||
92 | 92 | 'order' => 3 |
93 | 93 | ]; |
94 | 94 | } |
95 | - if ( $this->invoice->due |
|
96 | - && ( ( $this->invoice->due < time() |
|
95 | + if ($this->invoice->due |
|
96 | + && (($this->invoice->due < time() |
|
97 | 97 | && $this->invoice->paid == 0) |
98 | 98 | || $this->invoice->due < $this->invoice->paid)) { |
99 | 99 | $entries[] = [ |
@@ -27,7 +27,7 @@ |
||
27 | 27 | $prefix = $nap->get_node($this->_topic->id)[MIDCOM_NAV_ABSOLUTEURL]; |
28 | 28 | |
29 | 29 | $tree = new org_openpsa_widgets_tree(org_openpsa_contacts_group_dba::class, 'owner'); |
30 | - $tree->link_callback = function (string $guid) use ($prefix) { |
|
30 | + $tree->link_callback = function(string $guid) use ($prefix) { |
|
31 | 31 | return $prefix . 'group/' . $guid . '/'; |
32 | 32 | }; |
33 | 33 | $tree->constraints[] = ['orgOpenpsaObtype', '<', org_openpsa_contacts_group_dba::ORGANIZATION]; |
@@ -109,7 +109,7 @@ |
||
109 | 109 | $attachment->update(); |
110 | 110 | } else { |
111 | 111 | $attachment = $this->invoice->create_attachment($filename, $this->invoice->get_label(), "application/pdf"); |
112 | - if ( !$attachment |
|
112 | + if (!$attachment |
|
113 | 113 | || !$this->invoice->set_parameter("midcom.helper.datamanager2.type.blobs", $name, $attachment->guid . ":" . $attachment->guid)) { |
114 | 114 | throw new midcom_error("Failed to create invoice attachment for pdf: " . midcom_connection::get_error_string()); |
115 | 115 | } |
@@ -125,7 +125,8 @@ discard block |
||
125 | 125 | try { |
126 | 126 | $pdf_helper->render_and_attach(); |
127 | 127 | return $this->reply(true, $this->_l10n->get('pdf created')); |
128 | - } catch (midcom_error $e) { |
|
128 | + } |
|
129 | + catch (midcom_error $e) { |
|
129 | 130 | return $this->reply(false, $this->_l10n->get('pdf creation failed') . ': ' . $e->getMessage()); |
130 | 131 | } |
131 | 132 | } |
@@ -136,7 +137,8 @@ discard block |
||
136 | 137 | try { |
137 | 138 | $pdf_helper->render_and_attach('reminder'); |
138 | 139 | return $this->reply(true, $this->_l10n->get('reminder pdf created')); |
139 | - } catch (midcom_error $e) { |
|
140 | + } |
|
141 | + catch (midcom_error $e) { |
|
140 | 142 | return $this->reply(false, $this->_l10n->get('reminder pdf creation failed') . ': ' . $e->getMessage()); |
141 | 143 | } |
142 | 144 | } |