Test Failed
Branch master (8d1702)
by Andreas
11:03
created
lib/net/nemein/wiki/handler/latest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
                     return;
51 51
                 }
52 52
 
53
-                if (   $history['date'] < $from
53
+                if ($history['date'] < $from
54 54
                     || $history['date'] > $to) {
55 55
                     // We can ignore revisions outside the timeframe
56 56
                     continue;
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
         $this->_seek_updated($from);
94 94
 
95 95
         $i = 0;
96
-        while (   $this->_updated_pages < $this->_max_pages
96
+        while ($this->_updated_pages < $this->_max_pages
97 97
                && $i < 20) {
98 98
             // Expand seek by another two weeks
99 99
             $to = $from;
Please login to merge, or discard this patch.
lib/net/nemein/wiki/wikipage.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
 
30 30
     public function _on_creating()
31 31
     {
32
-        if (   $this->title == ''
32
+        if ($this->title == ''
33 33
             || !$this->topic) {
34 34
             // We must have wikiword and topic at this stage
35 35
             return false;
Please login to merge, or discard this patch.
lib/net/nemein/rss/parser/item.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -61,7 +61,7 @@
 block discarded – undo
61 61
     public function get_link($key = 0, $rel = 'alternate')
62 62
     {
63 63
         $link = parent::get_link($key, $rel);
64
-        if (   $rel !== 'alternate'
64
+        if ($rel !== 'alternate'
65 65
             || $key !== 0) {
66 66
             return $link;
67 67
         }
Please login to merge, or discard this patch.
lib/net/nehmer/static/handler/create.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
         $this->_article = new midcom_db_article();
84 84
         $this->_article->topic = $this->_topic->id;
85 85
 
86
-        if (   array_key_exists('name', $this->_defaults)
86
+        if (array_key_exists('name', $this->_defaults)
87 87
             && $this->_defaults['name'] == 'index') {
88 88
             // Store this to article directly in case name field is not editable in schema
89 89
             $this->_article->name = 'index';
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
 
92 92
         if (!$this->_article->create()) {
93 93
             debug_print_r('We operated on this object:', $this->_article);
94
-            throw new midcom_error('Failed to create a new article. Last Midgard error was: '. midcom_connection::get_error_string());
94
+            throw new midcom_error('Failed to create a new article. Last Midgard error was: ' . midcom_connection::get_error_string());
95 95
         }
96 96
 
97 97
         // Callback possibility
Please login to merge, or discard this patch.
lib/net/nehmer/static/viewer.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@
 block discarded – undo
73 73
             }
74 74
         }
75 75
 
76
-        if (   $this->_topic->can_do('midgard:update')
76
+        if ($this->_topic->can_do('midgard:update')
77 77
             && $this->_topic->can_do('midcom:component_config')) {
78 78
             $buttons[] = $workflow->get_button('config/', array(
79 79
                 MIDCOM_TOOLBAR_LABEL => $this->_l10n_midcom->get('component configuration'),
Please login to merge, or discard this patch.
lib/net/nehmer/blog/navigation.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
 
42 42
         // Hide the articles that have the publish time in the future and if
43 43
         // the user is not administrator
44
-        if (   $this->_config->get('enable_scheduled_publishing')
44
+        if ($this->_config->get('enable_scheduled_publishing')
45 45
             && !midcom::get()->auth->admin) {
46 46
             // Show the article only if the publishing time has passed or the viewer
47 47
             // is the author
@@ -83,14 +83,14 @@  discard block
 block discarded – undo
83 83
 
84 84
     private function _add_pseudo_leaves(array &$leaves)
85 85
     {
86
-        if (   $this->_config->get('archive_enable')
86
+        if ($this->_config->get('archive_enable')
87 87
             && $this->_config->get('archive_in_navigation')) {
88 88
             $leaves["{$this->_topic->id}_ARCHIVE"] = array(
89 89
                 MIDCOM_NAV_URL => "archive/",
90 90
                 MIDCOM_NAV_NAME => $this->_l10n->get('archive'),
91 91
             );
92 92
         }
93
-        if (   $this->_config->get('rss_enable')
93
+        if ($this->_config->get('rss_enable')
94 94
             && $this->_config->get('feeds_in_navigation')) {
95 95
             $leaves[self::LEAFID_FEEDS] = array(
96 96
                 MIDCOM_NAV_URL => "feeds/",
@@ -98,7 +98,7 @@  discard block
 block discarded – undo
98 98
             );
99 99
         }
100 100
 
101
-        if (   $this->_config->get('categories_in_navigation')
101
+        if ($this->_config->get('categories_in_navigation')
102 102
             && $this->_config->get('categories') != '') {
103 103
             $categories = explode(',', $this->_config->get('categories'));
104 104
             foreach ($categories as $category) {
@@ -109,14 +109,14 @@  discard block
 block discarded – undo
109 109
             }
110 110
         }
111 111
 
112
-        if (   $this->_config->get('archive_years_in_navigation')
112
+        if ($this->_config->get('archive_years_in_navigation')
113 113
             && $this->_config->get('archive_years_enable')) {
114 114
             $qb = midcom_db_article::new_query_builder();
115 115
             $qb->add_constraint('topic', '=', $this->_topic->id);
116 116
 
117 117
             // Hide the articles that have the publish time in the future and if
118 118
             // the user is not administrator
119
-            if (   $this->_config->get('enable_scheduled_publishing')
119
+            if ($this->_config->get('enable_scheduled_publishing')
120 120
                 && !midcom::get()->auth->admin) {
121 121
                 // Show the article only if the publishing time has passed or the viewer
122 122
                 // is the author
Please login to merge, or discard this patch.
lib/net/nehmer/comments/handler/admin.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -137,7 +137,7 @@
 block discarded – undo
137 137
 
138 138
     private function _verify_post_data()
139 139
     {
140
-        if (   !array_key_exists('action', $_POST)
140
+        if (!array_key_exists('action', $_POST)
141 141
             || !array_key_exists('guid', $_POST)) {
142 142
             throw new midcom_error_notfound('Incomplete POST data');
143 143
         }
Please login to merge, or discard this patch.
lib/midcom/helper/exporter/xml.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@
 block discarded – undo
80 80
      */
81 81
     public function array2data(array $array, $root_node = 'array', $prefix = '')
82 82
     {
83
-        $data  = "{$prefix}<{$root_node}>\n";
83
+        $data = "{$prefix}<{$root_node}>\n";
84 84
 
85 85
         foreach ($array as $key => $field) {
86 86
             if (is_numeric($key)) {
Please login to merge, or discard this patch.
lib/midcom/helper/misc.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -252,7 +252,7 @@  discard block
 block discarded – undo
252 252
             return $data;
253 253
         }
254 254
 
255
-        $preg='/s:([0-9]+):"(.*?)";/ms';
255
+        $preg = '/s:([0-9]+):"(.*?)";/ms';
256 256
         preg_match_all($preg, $data, $matches);
257 257
         $cache = array();
258 258
 
@@ -348,13 +348,13 @@  discard block
 block discarded – undo
348 348
             $theme_path = implode('/', $path_array);
349 349
             $candidates = array();
350 350
             if ($substyle) {
351
-                $candidates[] =  $theme_root . $theme_path .  "/style/{$substyle}/{$element_name}.php";
351
+                $candidates[] = $theme_root . $theme_path . "/style/{$substyle}/{$element_name}.php";
352 352
             }
353 353
             if ($page) {
354
-                $candidates[] =  $theme_root . $theme_path .  "/style{$page}/{$element_name}.php";
354
+                $candidates[] = $theme_root . $theme_path . "/style{$page}/{$element_name}.php";
355 355
             }
356 356
 
357
-            $candidates[] = $theme_root . $theme_path .  "/style/{$element_name}.php";
357
+            $candidates[] = $theme_root . $theme_path . "/style/{$element_name}.php";
358 358
 
359 359
             foreach (array_filter($candidates, 'file_exists') as $candidate) {
360 360
                 return file_get_contents($candidate);
Please login to merge, or discard this patch.