Test Setup Failed
Pull Request — master (#190)
by
unknown
11:48 queued 03:14
created
lib/midcom/db/topic.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
     public function _on_loaded()
31 31
     {
32 32
         // if we are missing the component, use the nullcomponent.
33
-        if (   !$this->component
33
+        if (!$this->component
34 34
             || !array_key_exists($this->component, midcom::get()->componentloader->manifests)) {
35 35
             debug_add("Topic {$this->id} has no component assigned to it, using 'midcom.core.nullcomponent'.",
36 36
             MIDCOM_LOG_INFO);
Please login to merge, or discard this patch.
lib/midcom/response/styled.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@
 block discarded – undo
49 49
             $this->context->set_key(MIDCOM_CONTEXT_PAGETITLE, $meta[MIDCOM_NAV_NAME]);
50 50
         }
51 51
 
52
-        if (   $this->context->id == 0
52
+        if ($this->context->id == 0
53 53
             && !midcom::get()->skip_page_style) {
54 54
             // Let metadata service add its meta tags
55 55
             midcom::get()->metadata->populate_meta_head();
Please login to merge, or discard this patch.
lib/midcom/response/relocate.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -28,14 +28,14 @@
 block discarded – undo
28 28
 
29 29
     public function send()
30 30
     {
31
-        if (   $this->url == ''
32
-            || (   substr($this->url, 0, 1) != "/")
31
+        if ($this->url == ''
32
+            || (substr($this->url, 0, 1) != "/")
33 33
                 && !preg_match('|^https?://|', $this->url)) {
34 34
             $prefix = midcom_core_context::get()->get_key(MIDCOM_CONTEXT_ANCHORPREFIX);
35 35
             if ($prefix == '') {
36 36
                 $prefix = '/';
37 37
             }
38
-            $this->url =  "{$prefix}{$this->url}";
38
+            $this->url = "{$prefix}{$this->url}";
39 39
             debug_add("This is a relative URL from the local site, prepending anchor prefix: {$this->url}");
40 40
         }
41 41
         $location = "Location: {$this->url}";
Please login to merge, or discard this patch.
lib/midcom/style/dm2_config_recreate.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@
 block discarded – undo
9 9
         continue;
10 10
     }
11 11
 
12
-    if (   !$object->can_do('midgard:update')
12
+    if (!$object->can_do('midgard:update')
13 13
         || !$object->can_do('midgard:attachments')) {
14 14
         printf(midcom::get()->i18n->get_string('not recreating object %s %s, reason %s', 'midcom'), $type, $object->guid, 'Insufficient privileges') . "\n";
15 15
         continue;
Please login to merge, or discard this patch.
lib/midcom/services/session.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -78,7 +78,7 @@
 block discarded – undo
78 78
      */
79 79
     public function __construct($context = null)
80 80
     {
81
-        if (   is_null($context)
81
+        if (is_null($context)
82 82
             || is_numeric($context)) {
83 83
             $this->_domain = midcom_core_context::get($context)->get_key(MIDCOM_CONTEXT_COMPONENT);
84 84
         } else {
Please login to merge, or discard this patch.
lib/midcom/services/i18n/formatter.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
 
30 30
     public function number($value, $precision = 2)
31 31
     {
32
-        if (   is_float($value)
32
+        if (is_float($value)
33 33
             && version_compare(Intl::getIcuVersion(), '49', '<')) {
34 34
             // workaround for http://bugs.icu-project.org/trac/ticket/8561
35 35
             if ($precision == 0) {
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
             $value = time();
58 58
         }
59 59
         //PHP < 5.3.4 compat
60
-        if (   version_compare(PHP_VERSION, '5.3.5', '<')
60
+        if (version_compare(PHP_VERSION, '5.3.5', '<')
61 61
             && $value instanceof DateTime) {
62 62
             $value = (int) $value->format('U') + timezone_offset_get($value->getTimeZone(), $value);
63 63
         }
Please login to merge, or discard this patch.
lib/midcom/services/permalinks/main.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -94,7 +94,7 @@
 block discarded – undo
94 94
         if (is_a($object, 'midcom_db_attachment')) {
95 95
             // Faster linking to attachments
96 96
             $parent = $object->get_parent();
97
-            if (   is_a($parent, 'midcom_db_topic')
97
+            if (is_a($parent, 'midcom_db_topic')
98 98
                 && $nav->is_node_in_tree($parent->id, $nav->get_root_node())) {
99 99
                 $napobj = $nav->get_node($parent->id);
100 100
                 return $napobj[MIDCOM_NAV_FULLURL] . $object->name;
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -72,7 +72,8 @@
 block discarded – undo
72 72
 
73 73
         try {
74 74
             $object = midcom::get()->dbfactory->get_object_by_guid($guid);
75
-        } catch (midcom_error $e) {
75
+        }
76
+        catch (midcom_error $e) {
76 77
             debug_add("Failed to resolve the GUID {$guid}, this is most probably an access denied error.", MIDCOM_LOG_ERROR);
77 78
             debug_add('Last MidCOM error string: ' . $e->getMessage());
78 79
             return null;
Please login to merge, or discard this patch.
lib/midcom/services/indexer/backend/solr.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -213,7 +213,8 @@
 block discarded – undo
213 213
         $browser = new Browser;
214 214
         try {
215 215
             $response = $browser->send($request);
216
-        } catch (Exception $e) {
216
+        }
217
+        catch (Exception $e) {
217 218
             debug_add("Failed to execute request " . $request->getUrl() . ": " . $e->getMessage(), MIDCOM_LOG_WARN);
218 219
             return false;
219 220
         }
Please login to merge, or discard this patch.
lib/midcom/services/indexer/document/midcom.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -109,7 +109,7 @@
 block discarded – undo
109 109
      */
110 110
     public function members_to_fields()
111 111
     {
112
-        if (   empty($this->topic_guid)
112
+        if (empty($this->topic_guid)
113 113
             || empty($this->topic_url)
114 114
             || empty($this->component)) {
115 115
             //if one of those is missing, we override all three to ensure consistency
Please login to merge, or discard this patch.