Test Failed
Branch dev (2230d2)
by Michael
38:39
created
form/_view/sectionset/AdminPageFramework_Form_View___FieldsetTableRow.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
 
33 33
         $_aParameters = func_get_args() + array(
34 34
             $this->aFieldset,
35
-            $this->aSavedData,    // passed by reference. @todo: examine why it needs to be passed by reference.
35
+            $this->aSavedData, // passed by reference. @todo: examine why it needs to be passed by reference.
36 36
             $this->aFieldErrors,
37 37
             $this->aFieldTypeDefinitions,
38 38
             $this->aCallbacks, // field output element callables.
@@ -60,14 +60,14 @@  discard block
 block discarded – undo
60 60
 
61 61
         $aFieldset = $this->aFieldset;
62 62
 
63
-        if ( ! $this->isNormalPlacement( $aFieldset ) ) {
63
+        if ( !$this->isNormalPlacement( $aFieldset ) ) {
64 64
             return '';
65 65
         }
66 66
 
67
-        $_oFieldrowAttribute   = new AdminPageFramework_Form_View___Attribute_Fieldrow(
67
+        $_oFieldrowAttribute = new AdminPageFramework_Form_View___Attribute_Fieldrow(
68 68
             $aFieldset,
69 69
             array(
70
-                'id'        => 'fieldrow-' . $aFieldset[ 'tag_id' ],
70
+                'id'        => 'fieldrow-'.$aFieldset[ 'tag_id' ],
71 71
                 'valign'    => 'top',
72 72
                 'class'     => 'admin-page-framework-fieldrow',
73 73
             )
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
         return $this->_getFieldByContainer(
77 77
             $aFieldset,
78 78
             array(
79
-                'open_container'    => "<tr " . $_oFieldrowAttribute->get() . ">",
79
+                'open_container'    => "<tr ".$_oFieldrowAttribute->get().">",
80 80
                 'close_container'   => "</tr>",
81 81
                 'open_title'        => "<th>",
82 82
                 'close_title'       => "</th>",
@@ -125,13 +125,13 @@  discard block
 block discarded – undo
125 125
                 $this->aCallbacks,
126 126
                 $this->oMsg
127 127
             );
128
-            $_aOutput   = array();
128
+            $_aOutput = array();
129 129
             if ( $aFieldset[ 'show_title_column' ] ) {
130
-                $_aOutput[] = $aOpenCloseTags[ 'open_title' ]
130
+                $_aOutput[ ] = $aOpenCloseTags[ 'open_title' ]
131 131
                         . $_oFieldTitle->get()
132 132
                     . $aOpenCloseTags[ 'close_title' ];
133 133
             }
134
-            $_aOutput[] = $aOpenCloseTags[ 'open_main' ]
134
+            $_aOutput[ ] = $aOpenCloseTags[ 'open_main' ]
135 135
                     // . call_user_func_array( $hfCallback, array( $aFieldset ) )
136 136
                     . $this->getFieldsetOutput( $aFieldset )
137 137
                 . $aOpenCloseTags[ 'close_main' ];
Please login to merge, or discard this patch.
form/_view/sectionset/AdminPageFramework_Form_View___FieldsetRow.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
 
32 32
         $_aParameters = func_get_args() + array(
33 33
             $this->aFieldset,
34
-            $this->aSavedData,    // passed by reference. @todo: examine why it needs to be passed by reference.
34
+            $this->aSavedData, // passed by reference. @todo: examine why it needs to be passed by reference.
35 35
             $this->aFieldErrors,
36 36
             $this->aFieldTypeDefinitions,
37 37
             $this->aCallbacks, // field output element callables.
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
 
60 60
         $aFieldset = $this->aFieldset;
61 61
 
62
-        if ( ! $this->isNormalPlacement( $aFieldset ) ) {
62
+        if ( !$this->isNormalPlacement( $aFieldset ) ) {
63 63
             return '';
64 64
         }
65 65
 
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
         return $this->_getFieldByContainer(
71 71
             $aFieldset,
72 72
             array(
73
-                'open_main'     => "<div " . $_oFieldrowAttribute->get() . ">",
73
+                'open_main'     => "<div ".$_oFieldrowAttribute->get().">",
74 74
                 'close_main'    => "</div>",
75 75
             )
76 76
         );
Please login to merge, or discard this patch.
generator/field/AdminPageFramework_Form_View___Generate_FieldInputName.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -54,9 +54,9 @@
 block discarded – undo
54 54
         $_sIndex = $this->getAOrB(
55 55
             '0' !== $this->sIndex && empty( $this->sIndex ),
56 56
             '',
57
-            "[" . $this->sIndex . "]"
57
+            "[".$this->sIndex."]"
58 58
         );
59
-        return $this->_getFiltered( $this->_getFieldName() . $_sIndex );
59
+        return $this->_getFiltered( $this->_getFieldName().$_sIndex );
60 60
 
61 61
     }
62 62
 
Please login to merge, or discard this patch.
field/AdminPageFramework_Form_View___Generate_FlatFieldInputName.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
             '',
38 38
             "|{$this->sIndex}"
39 39
         );
40
-        return $this->_getFiltered( $this->_getFlatFieldName() . $_sIndex );
40
+        return $this->_getFiltered( $this->_getFlatFieldName().$_sIndex );
41 41
 
42 42
     }
43 43
 
Please login to merge, or discard this patch.
generator/field/AdminPageFramework_Form_View___Generate_FieldTagID.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
      * @return      string
40 40
      */
41 41
     public function getModel() {
42
-        return $this->get() . '__' . $this->sIndexMark;
42
+        return $this->get().'__'.$this->sIndexMark;
43 43
     }
44 44
         /**
45 45
          * @since       3.6.0
@@ -49,17 +49,17 @@  discard block
 block discarded – undo
49 49
 
50 50
             // 3.8.0+
51 51
             if ( $this->aArguments[ '_parent_tag_id' ] ) {
52
-                return $this->aArguments[ '_parent_tag_id' ] . '_' . $this->aArguments[ 'field_id' ];
52
+                return $this->aArguments[ '_parent_tag_id' ].'_'.$this->aArguments[ 'field_id' ];
53 53
             }
54 54
 
55 55
             $_sSectionIndex = isset( $this->aArguments[ '_section_index' ] )
56
-                ? '__' . $this->aArguments[ '_section_index' ]
56
+                ? '__'.$this->aArguments[ '_section_index' ]
57 57
                 : '';
58 58
             $_sSectionPart = implode( '_', $this->aArguments[ '_section_path_array' ] );
59 59
             $_sFieldPart   = implode( '_', $this->aArguments[ '_field_path_array' ] );
60 60
 
61 61
             return $this->_isSectionSet()
62
-                ? $_sSectionPart . $_sSectionIndex . '_' . $_sFieldPart
62
+                ? $_sSectionPart.$_sSectionIndex.'_'.$_sFieldPart
63 63
                 : $_sFieldPart;
64 64
 
65 65
         }
Please login to merge, or discard this patch.
factory/_common/_abstract/_controller/AdminPageFramework_HelpPane_Base.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
      * @since 2.1.0
54 54
      * @internal
55 55
      */
56
-    protected function _setHelpTab( $sID, $sTitle, $aContents, $aSideBarContents=array() ) {
56
+    protected function _setHelpTab( $sID, $sTitle, $aContents, $aSideBarContents = array() ) {
57 57
 
58 58
         if ( empty( $aContents ) ) {
59 59
             return;
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
             )
71 71
         );
72 72
 
73
-        if ( ! empty( $aSideBarContents ) ) {
73
+        if ( !empty( $aSideBarContents ) ) {
74 74
             $this->_oScreen->set_help_sidebar( implode( PHP_EOL, $aSideBarContents ) );
75 75
         }
76 76
 
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
      * @internal
83 83
      */
84 84
     protected function _formatHelpDescription( $sHelpDescription ) {
85
-        return "<div class='contextual-help-description'>" . $sHelpDescription . "</div>";
85
+        return "<div class='contextual-help-description'>".$sHelpDescription."</div>";
86 86
     }
87 87
 
88 88
 
@@ -106,10 +106,10 @@  discard block
 block discarded – undo
106 106
      * @remark      This method just adds the given text into the class property. The actual registration will be performed with the <em>replyToRegisterHelpTabTextForMetaBox()</em> method.
107 107
      * @internal
108 108
      */
109
-    public function _addHelpText( $sHTMLContent, $sHTMLSidebarContent="" ) {
109
+    public function _addHelpText( $sHTMLContent, $sHTMLSidebarContent = "" ) {
110 110
 
111
-        $this->oProp->aHelpTabText[]        = "<div class='contextual-help-description'>" . $sHTMLContent . "</div>";
112
-        $this->oProp->aHelpTabTextSide[]    = "<div class='contextual-help-description'>" . $sHTMLSidebarContent . "</div>";
111
+        $this->oProp->aHelpTabText[ ]        = "<div class='contextual-help-description'>".$sHTMLContent."</div>";
112
+        $this->oProp->aHelpTabTextSide[ ]    = "<div class='contextual-help-description'>".$sHTMLSidebarContent."</div>";
113 113
 
114 114
     }
115 115
 
@@ -125,9 +125,9 @@  discard block
 block discarded – undo
125 125
      * @remark      This method just adds the given text into the class property. The actual registration will be performed with the `replyToRegisterHelpTabTextForMetaBox()` method.
126 126
      * @internal
127 127
      */
128
-    public function _addHelpTextForFormFields( $sFieldTitle, $sHelpText, $sHelpTextSidebar="" ) {
128
+    public function _addHelpTextForFormFields( $sFieldTitle, $sHelpText, $sHelpTextSidebar = "" ) {
129 129
         $this->_addHelpText(
130
-            "<span class='contextual-help-tab-title'>" . $sFieldTitle . "</span> - " . PHP_EOL
130
+            "<span class='contextual-help-tab-title'>".$sFieldTitle."</span> - ".PHP_EOL
131 131
                 . $sHelpText,
132 132
             $sHelpTextSidebar
133 133
         );
@@ -145,7 +145,7 @@  discard block
 block discarded – undo
145 145
     public function _replyToRegisterHelpTabText() {
146 146
 
147 147
         // Check if the currently loaded page is of meta box page.
148
-        if ( ! $this->oProp->oCaller->isInThePage() ) {
148
+        if ( !$this->oProp->oCaller->isInThePage() ) {
149 149
             return false;
150 150
         }
151 151
 
Please login to merge, or discard this patch.
factory/_common/_abstract/_controller/AdminPageFramework_Link_Base.php 1 patch
Spacing   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -25,9 +25,9 @@  discard block
 block discarded – undo
25 25
     /**
26 26
      * Sets up hooks and properties.
27 27
      */
28
-    public function __construct( $oProp, $oMsg=null ) {
28
+    public function __construct( $oProp, $oMsg = null ) {
29 29
 
30
-        if ( ! $this->_isLoadable( $oProp ) ) {
30
+        if ( !$this->_isLoadable( $oProp ) ) {
31 31
             return;
32 32
         }
33 33
 
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
         // Add an action link in the plugin listing page
40 40
         if ( $this->_shouldSetPluginActionLinks() ) {
41 41
             add_filter(
42
-                'plugin_action_links_' . plugin_basename( $this->oProp->aScriptInfo[ 'sPath' ] ),
42
+                'plugin_action_links_'.plugin_basename( $this->oProp->aScriptInfo[ 'sPath' ] ),
43 43
                 array( $this, '_replyToAddSettingsLinkInPluginListingPage' ),
44 44
                 20     // set a lower priority so that the link will be embedded at the beginning ( the most left hand side ).
45 45
             );
@@ -54,13 +54,13 @@  discard block
 block discarded – undo
54 54
          * @return      boolean
55 55
          */
56 56
         private function _isLoadable( $oProp ) {
57
-            if ( ! $oProp->bIsAdmin ) {
57
+            if ( !$oProp->bIsAdmin ) {
58 58
                 return false;
59 59
             }
60 60
             if ( $oProp->bIsAdminAjax ) {
61 61
                 return false;
62 62
             }
63
-            return ! $this->hasBeenCalled( 'links_' . $oProp->sClassName );
63
+            return !$this->hasBeenCalled( 'links_'.$oProp->sClassName );
64 64
         }
65 65
 
66 66
     /**
@@ -84,11 +84,11 @@  discard block
 block discarded – undo
84 84
     protected function _shouldSetPluginActionLinks() {
85 85
 
86 86
         // It is possible that the sub-objects are not set when the class is considered not loadable.
87
-        if ( ! isset( $this->oProp ) ) {
87
+        if ( !isset( $this->oProp ) ) {
88 88
             return false;
89 89
         }
90 90
 
91
-        if ( ! in_array( $this->oProp->sPageNow, array( 'plugins.php' ) ) ) {
91
+        if ( !in_array( $this->oProp->sPageNow, array( 'plugins.php' ) ) ) {
92 92
             return false;
93 93
         }
94 94
         return 'plugin' === $this->oProp->aScriptInfo[ 'sType' ];
@@ -155,7 +155,7 @@  discard block
 block discarded – undo
155 155
                         array(
156 156
                             'href'      => $aScriptInfo[ 'sURI' ],
157 157
                             'target'    => '_blank',
158
-                            'title'     => $aScriptInfo[ 'sName' ] . $_sVersion . $_sDescription
158
+                            'title'     => $aScriptInfo[ 'sName' ].$_sVersion.$_sDescription
159 159
                         ),
160 160
                         $aScriptInfo[ 'sName' ]
161 161
                     )
@@ -177,13 +177,13 @@  discard block
 block discarded – undo
177 177
                 $_sAuthorInfo = $this->getAOrB(
178 178
                     empty( $aScriptInfo[ 'sAuthor' ] ),
179 179
                     $_sAuthorInfo,
180
-                    ' by ' . $_sAuthorInfo
180
+                    ' by '.$_sAuthorInfo
181 181
                 );
182 182
 
183 183
                 // Enclosing the output in a span tag as the outer element is a '<p>' tag. So this cannot be div.
184 184
                 // 3.5.7+ Added the class attribute for acceptance testing
185 185
                 return "<span class='apf-script-info'>"
186
-                        . $_sPluginInfo . $_sAuthorInfo
186
+                        . $_sPluginInfo.$_sAuthorInfo
187 187
                     . "</span>";
188 188
 
189 189
             }
@@ -214,7 +214,7 @@  discard block
 block discarded – undo
214 214
                         array(
215 215
                             'href'      => $aScriptInfo[ 'sURI' ],
216 216
                             'target'    => '_blank',
217
-                            'title'     => $aScriptInfo[ 'sName' ] . $_sVersion . $_sDescription,
217
+                            'title'     => $aScriptInfo[ 'sName' ].$_sVersion.$_sDescription,
218 218
                         ),
219 219
                         $aScriptInfo[ 'sName' ]
220 220
                     )
@@ -224,16 +224,16 @@  discard block
 block discarded – undo
224 224
                 // 3.5.7+ added the 'apf-credit' class attribute for acceptance testing
225 225
                 // 3.7.0+  added the footer-thankyou id attribute.
226 226
                 return "<span class='apf-credit' id='footer-thankyou'>"
227
-                    . $this->oMsg->get( 'powered_by' ) . '&nbsp;'
227
+                    . $this->oMsg->get( 'powered_by' ).'&nbsp;'
228 228
                     . $_sLibraryInfo
229 229
                     . ",&nbsp;"
230
-                    . $this->oMsg->get( 'and' ) . '&nbsp;'
230
+                    . $this->oMsg->get( 'and' ).'&nbsp;'
231 231
                     . $this->getHTMLTag(
232 232
                         'a',
233 233
                         array(
234 234
                             'href'      => 'https://wordpress.org',
235 235
                             'target'    => '_blank',
236
-                            'title'     => 'WordPress ' . $GLOBALS[ 'wp_version' ]
236
+                            'title'     => 'WordPress '.$GLOBALS[ 'wp_version' ]
237 237
                         ),
238 238
                         'WordPress'
239 239
                     )
@@ -249,7 +249,7 @@  discard block
 block discarded – undo
249 249
          */
250 250
         protected function _setFooterHooks() {
251 251
 
252
-            add_filter( 'admin_footer_text' , array( $this, '_replyToAddInfoInFooterLeft' ) );
252
+            add_filter( 'admin_footer_text', array( $this, '_replyToAddInfoInFooterLeft' ) );
253 253
             add_filter( 'update_footer', array( $this, '_replyToAddInfoInFooterRight' ), 11 );
254 254
 
255 255
         }
@@ -261,7 +261,7 @@  discard block
 block discarded – undo
261 261
              * @callback    filter      admin_footer_text
262 262
              * @internal
263 263
              */
264
-            public function _replyToAddInfoInFooterLeft( $sLinkHTML='' ) {
264
+            public function _replyToAddInfoInFooterLeft( $sLinkHTML = '' ) {
265 265
 
266 266
                 $sLinkHTML = empty( $this->oProp->aScriptInfo[ 'sName' ] )
267 267
                     ? $sLinkHTML
@@ -269,7 +269,7 @@  discard block
 block discarded – undo
269 269
 
270 270
                 return $this->addAndApplyFilters(
271 271
                     $this->oProp->oCaller,
272
-                    'footer_left_' . $this->oProp->sClassName,
272
+                    'footer_left_'.$this->oProp->sClassName,
273 273
                     $sLinkHTML
274 274
                 );
275 275
 
@@ -282,10 +282,10 @@  discard block
 block discarded – undo
282 282
              * @callback    filter      admin_footer_text
283 283
              * @internal
284 284
              */
285
-            public function _replyToAddInfoInFooterRight( $sLinkHTML='' ) {
285
+            public function _replyToAddInfoInFooterRight( $sLinkHTML = '' ) {
286 286
                 return $this->addAndApplyFilters(
287 287
                     $this->oProp->oCaller,
288
-                    'footer_right_' . $this->oProp->sClassName,
288
+                    'footer_right_'.$this->oProp->sClassName,
289 289
                     $this->oProp->aFooterInfo[ 'sRight' ]
290 290
                 );
291 291
             }
Please login to merge, or discard this patch.
development/factory/_common/_abstract/AdminPageFramework_Factory_View.php 2 patches
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
          * @return      string      the input id attribute
41 41
          */
42 42
         public function _replyToGetSectionName( /* $sSectionName, $aSectionset */ ) {
43
-            $_aParams = func_get_args() + array( null, null, );
43
+            $_aParams = func_get_args() + array( null, null,);
44 44
             return $_aParams[ 0 ];
45 45
         }
46 46
 
@@ -68,8 +68,8 @@  discard block
 block discarded – undo
68 68
          * @since       3.6.0
69 69
          * @return      string
70 70
          */
71
-        public function _replyToGetFieldNameAttribute( /* $sFieldName, $aFieldset */ )  {
72
-            $_aParams = func_get_args() + array( null, null, );
71
+        public function _replyToGetFieldNameAttribute( /* $sFieldName, $aFieldset */ ) {
72
+            $_aParams = func_get_args() + array( null, null,);
73 73
             return $_aParams[ 0 ];
74 74
         }
75 75
         /**
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
          * @return      string
80 80
          */
81 81
         public function _replyToGetFlatFieldName( /* $sFieldName, $aFieldset */ ) {
82
-            $_aParams = func_get_args() + array( null, null, );
82
+            $_aParams = func_get_args() + array( null, null,);
83 83
             return $_aParams[ 0 ];
84 84
         }
85 85
 
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
          * @return      string      the flat input name attribute
102 102
          */
103 103
         public function _replyToGetFlatInputName( /* $sFlatNameAttribute, $aField, $sKey */ ) {
104
-            $_aParams   = func_get_args() + array( null, null, null );
104
+            $_aParams = func_get_args() + array( null, null, null );
105 105
             return $_aParams[ 0 ];
106 106
         }
107 107
 
@@ -143,14 +143,14 @@  discard block
 block discarded – undo
143 143
                 'if'            => true,
144 144
                 'capability'    => '',
145 145
             );
146
-            if ( ! $aElementDefinition[ 'if' ] ) {
146
+            if ( !$aElementDefinition[ 'if' ] ) {
147 147
                 return false;
148 148
             }
149 149
             // For front-end forms that allow guests, the capability level can be empty. In that case, return true.
150
-            if ( ! $aElementDefinition[ 'capability' ] ) {
150
+            if ( !$aElementDefinition[ 'capability' ] ) {
151 151
                 return true;
152 152
             }
153
-            if ( ! current_user_can( $aElementDefinition[ 'capability' ] ) ) {
153
+            if ( !current_user_can( $aElementDefinition[ 'capability' ] ) ) {
154 154
                 return false;
155 155
             }
156 156
             return $bDefault;
@@ -186,7 +186,7 @@  discard block
 block discarded – undo
186 186
             $this,
187 187
             array(
188 188
                 // section_{instantiated class name}_{section id}
189
-                'section_head_' . $this->oProp->sClassName . '_' . $aSectionset[ 'section_id' ]
189
+                'section_head_'.$this->oProp->sClassName.'_'.$aSectionset[ 'section_id' ]
190 190
             ),
191 191
             $sSectionDescription
192 192
         );
@@ -203,15 +203,15 @@  discard block
 block discarded – undo
203 203
      */
204 204
     public function _replyToGetFieldOutput( $sFieldOutput, $aFieldset ) {
205 205
 
206
-        $_sSectionPart  = $this->oUtil->getAOrB(
206
+        $_sSectionPart = $this->oUtil->getAOrB(
207 207
             isset( $aFieldset[ 'section_id' ] ) && '_default' !== $aFieldset[ 'section_id' ],
208
-            '_' . $aFieldset[ 'section_id' ],
208
+            '_'.$aFieldset[ 'section_id' ],
209 209
             ''
210 210
         );
211 211
         return $this->oUtil->addAndApplyFilters(
212 212
             $this,
213 213
             array(
214
-                'field_' . $this->oProp->sClassName . $_sSectionPart . '_' . $aFieldset[ 'field_id' ]
214
+                'field_'.$this->oProp->sClassName.$_sSectionPart.'_'.$aFieldset[ 'field_id' ]
215 215
             ),
216 216
             $sFieldOutput,
217 217
             $aFieldset // the field array
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -68,7 +68,7 @@
 block discarded – undo
68 68
          * @since       3.6.0
69 69
          * @return      string
70 70
          */
71
-        public function _replyToGetFieldNameAttribute( /* $sFieldName, $aFieldset */ )  {
71
+        public function _replyToGetFieldNameAttribute( /* $sFieldName, $aFieldset */ ) {
72 72
             $_aParams = func_get_args() + array( null, null, );
73 73
             return $_aParams[ 0 ];
74 74
         }
Please login to merge, or discard this patch.
factory/_common/_abstract/_view/AdminPageFramework_TabNavigationBar.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
     /**
26 26
      * Stores the tab items.
27 27
      */
28
-    public $aTabs   = array();
28
+    public $aTabs = array();
29 29
 
30 30
     /**
31 31
      * Stores container attributes.
@@ -35,11 +35,11 @@  discard block
 block discarded – undo
35 35
     );
36 36
 
37 37
     public $aTab = array(
38
-        'slug'       => null,  // (string) tab slug (id)
39
-        'title'      => null,  // (string) tab title
40
-        'href'       => null,  // (string) link url
41
-        'disabled'   => null,  // (boolean)
42
-        'class'      => null,  // (string) class selector to append to the class attribute
38
+        'slug'       => null, // (string) tab slug (id)
39
+        'title'      => null, // (string) tab title
40
+        'href'       => null, // (string) link url
41
+        'disabled'   => null, // (boolean)
42
+        'class'      => null, // (string) class selector to append to the class attribute
43 43
         'attributes' => array(),
44 44
     );
45 45
 
@@ -58,11 +58,11 @@  discard block
 block discarded – undo
58 58
      * @param       array             $aTabs              An array holding each tab definitions
59 59
      * @param       array|string      $asActiveTabSlugs   The default tab slug.
60 60
      */
61
-    public function __construct( array $aTabs, $asActiveTabSlugs, $sTabTag='h2', $aAttributes=array( 'class' => 'nav-tab-wrapper', ), $aCallbacks=array() ) {
61
+    public function __construct( array $aTabs, $asActiveTabSlugs, $sTabTag = 'h2', $aAttributes = array( 'class' => 'nav-tab-wrapper',), $aCallbacks = array() ) {
62 62
 
63
-        $this->aCallbacks           = $aCallbacks + array(
63
+        $this->aCallbacks = $aCallbacks + array(
64 64
             'format'    => null,
65
-            'arguments' => null,  // custom arguments to pass to the callback functions.
65
+            'arguments' => null, // custom arguments to pass to the callback functions.
66 66
         );
67 67
         $this->aTabs                = $this->_getFormattedTabs( $aTabs );
68 68
         $this->aActiveSlugs         = $this->getAsArray( $asActiveTabSlugs );
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
          * @return      array
77 77
          */
78 78
         private function _getFormattedTabs( array $aTabs ) {
79
-            foreach( $aTabs as $_isKey => &$_aTab ) {
79
+            foreach ( $aTabs as $_isKey => &$_aTab ) {
80 80
                 $_aFormattedTab = $this->_getFormattedTab( $_aTab, $aTabs );
81 81
                 if ( isset( $_aFormattedTab[ 'slug' ] ) ) {
82 82
                     $_aTab = $_aFormattedTab;
@@ -127,12 +127,12 @@  discard block
 block discarded – undo
127 127
         private function _getTabs() {
128 128
 
129 129
             $_aOutput = array();
130
-            foreach( $this->aTabs as $_aTab ) {
130
+            foreach ( $this->aTabs as $_aTab ) {
131 131
                 $_sTab = $this->_getTab( $_aTab );
132
-                if ( ! $_sTab ) {
132
+                if ( !$_sTab ) {
133 133
                     continue;
134 134
                 }
135
-                $_aOutput[] = $_sTab;
135
+                $_aOutput[ ] = $_sTab;
136 136
             }
137 137
 
138 138
             $_aContainerAttributes = $this->aAttributes + array( 'class' => null );
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
 
144 144
             return empty( $_aOutput )
145 145
                 ? ''
146
-                : "<{$this->sTabTag} " . $this->getAttributes( $_aContainerAttributes ) . ">"
146
+                : "<{$this->sTabTag} ".$this->getAttributes( $_aContainerAttributes ).">"
147 147
                     . implode( '', $_aOutput )
148 148
                 . "</{$this->sTabTag}>";
149 149
 
Please login to merge, or discard this patch.