Passed
Push — master ( ce8007...f347c2 )
by Andreas
16:56 queued 06:20
created
lib/midcom/style/midcom_services_auth_access_denied.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@
 block discarded – undo
3 3
 $title = $this->data['midcom_services_auth_access_denied_title'];
4 4
 $login_warning = $this->data['midcom_services_auth_access_denied_login_warning'];
5 5
 
6
-midcom::get()->head->add_stylesheet(MIDCOM_STATIC_URL.'/midcom.services.auth/style.css');
6
+midcom::get()->head->add_stylesheet(MIDCOM_STATIC_URL . '/midcom.services.auth/style.css');
7 7
 ?>
8 8
 <!DOCTYPE html>
9 9
 <html lang="<?php echo midcom::get()->i18n->get_current_language(); ?>">
Please login to merge, or discard this patch.
lib/midcom/style/midcom_services_auth_login_page.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@
 block discarded – undo
2 2
 $title = $this->data['midcom_services_auth_show_login_page_title'];
3 3
 $login_warning = $this->data['midcom_services_auth_show_login_page_login_warning'];
4 4
 
5
-midcom::get()->head->add_stylesheet(MIDCOM_STATIC_URL.'/midcom.services.auth/style.css');
5
+midcom::get()->head->add_stylesheet(MIDCOM_STATIC_URL . '/midcom.services.auth/style.css');
6 6
 ?>
7 7
 <!DOCTYPE html>
8 8
 <html lang="<?php echo midcom::get()->i18n->get_current_language(); ?>">
Please login to merge, or discard this patch.
lib/org/openpsa/calendar/event/resource.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -42,7 +42,8 @@
 block discarded – undo
42 42
         }
43 43
         try {
44 44
             $resource = org_openpsa_calendar_resource_dba::get_cached($this->resource);
45
-        } catch (midcom_error $e) {
45
+        }
46
+        catch (midcom_error $e) {
46 47
             debug_add("Cannot fetch resource #{$this->resource} returning false", MIDCOM_LOG_INFO);
47 48
             return false;
48 49
         }
Please login to merge, or discard this patch.
lib/org/openpsa/invoices/invoice/item.php 2 patches
Braces   +6 added lines, -3 removed lines patch added patch discarded remove patch
@@ -66,7 +66,8 @@  discard block
 block discarded – undo
66 66
             try {
67 67
                 $task = org_openpsa_projects_task_dba::get_cached($this->task);
68 68
                 $url = $projects_url . 'task/' . $task->guid . '/';
69
-            } catch (midcom_error $e) {
69
+            }
70
+            catch (midcom_error $e) {
70 71
             }
71 72
         }
72 73
         if (   $url == ''
@@ -74,7 +75,8 @@  discard block
 block discarded – undo
74 75
             try {
75 76
                 $deliverable = org_openpsa_sales_salesproject_deliverable_dba::get_cached($this->deliverable);
76 77
                 $url = $sales_url . 'deliverable/' . $deliverable->guid . '/';
77
-            } catch (midcom_error $e) {
78
+            }
79
+            catch (midcom_error $e) {
78 80
             }
79 81
         }
80 82
         if ($url != '') {
@@ -96,7 +98,8 @@  discard block
 block discarded – undo
96 98
                     $deliverable = new org_openpsa_sales_salesproject_deliverable_dba($this->deliverable);
97 99
                     self::update_deliverable($deliverable);
98 100
                 }
99
-            } catch (midcom_error $e) {
101
+            }
102
+            catch (midcom_error $e) {
100 103
                 $e->log();
101 104
             }
102 105
         }
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
 
26 26
     public function _on_creating() : bool
27 27
     {
28
-        if (   $this->invoice
28
+        if ($this->invoice
29 29
             && $this->position == 0) {
30 30
             $invoice = org_openpsa_invoices_invoice_dba::get_cached($this->invoice);
31 31
             $this->position = count($invoice->get_invoice_items()) + 1;
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
             } catch (midcom_error $e) {
76 76
             }
77 77
         }
78
-        if (   $url == ''
78
+        if ($url == ''
79 79
             && $sales_url) {
80 80
             try {
81 81
                 $deliverable = org_openpsa_sales_salesproject_deliverable_dba::get_cached($this->deliverable);
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
                 $invoice = new org_openpsa_invoices_invoice_dba($this->invoice);
98 98
                 $old_sum = $invoice->sum;
99 99
                 self::update_invoice($invoice);
100
-                if (   $old_sum != $invoice->sum
100
+                if ($old_sum != $invoice->sum
101 101
                     && !empty($this->deliverable)) {
102 102
                     $deliverable = new org_openpsa_sales_salesproject_deliverable_dba($this->deliverable);
103 103
                     self::update_deliverable($deliverable);
@@ -135,7 +135,7 @@  discard block
 block discarded – undo
135 135
 
136 136
         if ($invoiced != $deliverable->invoiced) {
137 137
             $deliverable->invoiced = $invoiced;
138
-            if (   $deliverable->orgOpenpsaObtype !== org_openpsa_products_product_dba::DELIVERY_SUBSCRIPTION
138
+            if ($deliverable->orgOpenpsaObtype !== org_openpsa_products_product_dba::DELIVERY_SUBSCRIPTION
139 139
                 && $deliverable->state < org_openpsa_sales_salesproject_deliverable_dba::STATE_INVOICED) {
140 140
                 $deliverable->state = org_openpsa_sales_salesproject_deliverable_dba::STATE_INVOICED;
141 141
             }
Please login to merge, or discard this patch.
lib/org/openpsa/user/midcom/interfaces.php 1 patch
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,7 +25,8 @@  discard block
 block discarded – undo
25 25
         midcom::get()->auth->request_sudo($this->_component);
26 26
         try {
27 27
             $person = new midcom_db_person($args['guid']);
28
-        } catch (midcom_error $e) {
28
+        }
29
+        catch (midcom_error $e) {
29 30
             $handler->print_error('Person with guid #' . $args['guid'] . ' does not exist');
30 31
             midcom::get()->auth->drop_sudo();
31 32
             return false;
@@ -33,7 +34,8 @@  discard block
 block discarded – undo
33 34
         $accounthelper = new org_openpsa_user_accounthelper($person);
34 35
         try {
35 36
             $accounthelper->reopen_account();
36
-        } catch (midcom_error $e) {
37
+        }
38
+        catch (midcom_error $e) {
37 39
             $handler->print_error($e->getMessage());
38 40
             midcom::get()->auth->drop_sudo();
39 41
             return false;
Please login to merge, or discard this patch.
lib/org/openpsa/projects/task/status.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@
 block discarded – undo
63 63
     public function _on_created()
64 64
     {
65 65
         //Remove the resource if necessary
66
-        if (   $this->type == self::DECLINED
66
+        if ($this->type == self::DECLINED
67 67
             && $this->targetPerson) {
68 68
             $qb = org_openpsa_projects_task_resource_dba::new_query_builder();
69 69
             $qb->add_constraint('task', '=', $this->task);
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -95,7 +95,8 @@
 block discarded – undo
95 95
                     org_openpsa_projects_workflow::accept($task, 0, $this->comment);
96 96
                     return;
97 97
                 }
98
-            } catch (midcom_error $e) {
98
+            }
99
+            catch (midcom_error $e) {
99 100
                 $e->log();
100 101
             }
101 102
         }
Please login to merge, or discard this patch.
lib/org/openpsa/projects/status.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -68,7 +68,7 @@
 block discarded – undo
68 68
             $status_changer_label = $this->l10n->get('system');
69 69
             $target_person_label = $this->l10n->get('system');
70 70
 
71
-            if (    $status_change->metadata->creator
71
+            if ($status_change->metadata->creator
72 72
                  && $status_change->metadata->creator != $fallback_creator->guid) {
73 73
                 $status_changer = org_openpsa_widgets_contact::get($status_change->metadata->creator);
74 74
                 $status_changer_label = $status_changer->show_inline();
Please login to merge, or discard this patch.
lib/midcom/db/member.php 1 patch
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,7 +23,8 @@  discard block
 block discarded – undo
23 23
         try {
24 24
             $person = new midcom_db_person($this->uid);
25 25
             $grp = new midcom_db_group($this->gid);
26
-        } catch (midcom_error $e) {
26
+        }
27
+        catch (midcom_error $e) {
27 28
             $e->log();
28 29
             return 'Invalid membership record';
29 30
         }
@@ -40,7 +41,8 @@  discard block
 block discarded – undo
40 41
         }
41 42
         try {
42 43
             $person = new midcom_db_person($this->uid);
43
-        } catch (midcom_error $e) {
44
+        }
45
+        catch (midcom_error $e) {
44 46
             return;
45 47
         }
46 48
         midcom::get()->cache->invalidate($person->guid);
Please login to merge, or discard this patch.
lib/midcom/helper/toolbar/node.php 2 patches
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -88,7 +88,8 @@
 block discarded – undo
88 88
                         $style = midcom_db_style::get_cached($style_id);
89 89
                         $styleeditor_url = midcom_connection::get_url('self') . "__mfa/asgard/object/view/{$style->guid}/";
90 90
                         $enabled = true;
91
-                    } catch (midcom_error $e) {
91
+                    }
92
+                    catch (midcom_error $e) {
92 93
                         $e->log();
93 94
                     }
94 95
                 }
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
         }
58 58
         $buttons = [];
59 59
         $workflow = new midcom\workflow\datamanager;
60
-        if (   $this->topic->can_do('midgard:update')
60
+        if ($this->topic->can_do('midgard:update')
61 61
             && $this->topic->can_do('midcom.admin.folder:topic_management')) {
62 62
             $buttons[] = $workflow->get_button("__ais/folder/edit/", [
63 63
                 MIDCOM_TOOLBAR_LABEL => midcom::get()->i18n->get_string('edit folder', 'midcom.admin.folder'),
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
             ];
92 92
         }
93 93
         $buttons = array_merge($buttons, $this->get_approval_controls($this->topic, false));
94
-        if (   $this->topic->can_do('midcom.admin.folder:template_management')
94
+        if ($this->topic->can_do('midcom.admin.folder:template_management')
95 95
             && midcom::get()->auth->can_user_do('midgard.admin.asgard:manage_objects', null, 'midgard_admin_asgard_plugin')) {
96 96
             $enabled = false;
97 97
             $styleeditor_url = '';
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
                     MIDCOM_TOOLBAR_ACCESSKEY => 'f',
125 125
                 ]);
126 126
             }
127
-            if (   $this->topic->guid !== midcom::get()->config->get('midcom_root_topic_guid')
127
+            if ($this->topic->guid !== midcom::get()->config->get('midcom_root_topic_guid')
128 128
                 && $this->topic->can_do('midgard:delete')) {
129 129
                 $workflow = new midcom\workflow\delete(['object' => $this->topic, 'recursive' => true]);
130 130
                 $buttons[] = $workflow->get_button("__ais/folder/delete/", [
Please login to merge, or discard this patch.