Completed
Branch master (5cc763)
by
unknown
24:25 queued 19:39
created
admin-page-framework-loader.php 1 patch
Braces   +5 added lines, -4 removed lines patch added patch discarded remove patch
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
      * @return      void
186 186
      */ 
187 187
     static public function setAdminNotice( $sMessage, $sClassAttribute='error' ) {
188
-        if ( ! is_admin() ) {  
188
+        if ( ! is_admin() ) {
189 189
             return; 
190 190
         }
191 191
         self::$_aAdminNotices[] = array(
@@ -200,7 +200,7 @@  discard block
 block discarded – undo
200 200
          * @return      void
201 201
          */
202 202
         static public function _replyToSetAdminNotice() {
203
-            foreach( self::$_aAdminNotices as $_aAdminNotice ) {                
203
+            foreach( self::$_aAdminNotices as $_aAdminNotice ) {
204 204
                 echo "<div class='" . esc_attr( $_aAdminNotice['class_attribute'] ) . " notice is-dismissible'>"
205 205
                         ."<p>" 
206 206
                             . sprintf( 
@@ -221,7 +221,7 @@  discard block
 block discarded – undo
221 221
 if ( defined( 'DOING_UNINSTALL' ) ) { return; }
222 222
 
223 223
 // Include the library file 
224
-if ( ! class_exists( 'AdminPageFramework' ) ) {    
224
+if ( ! class_exists( 'AdminPageFramework' ) ) {
225 225
     // The development version is available in the repository cloned via GitHub.
226 226
     $_sDevelopmentVersionPath = dirname( __FILE__ ) . '/development/admin-page-framework.php';
227 227
     $_bDebugMode              = defined( 'WP_DEBUG' ) && WP_DEBUG;
@@ -250,7 +250,8 @@  discard block
 block discarded – undo
250 250
 
251 251
 // Include the framework loader plugin components.
252 252
 include( AdminPageFrameworkLoader_Registry::$sDirPath . '/include/class/boot/AdminPageFrameworkLoader_Bootstrap.php' );
253
-if ( class_exists( 'AdminPageFrameworkLoader_Bootstrap' ) ) {   // for backward compatibility
253
+if ( class_exists( 'AdminPageFrameworkLoader_Bootstrap' ) ) {
254
+// for backward compatibility
254 255
     new AdminPageFrameworkLoader_Bootstrap( 
255 256
         AdminPageFrameworkLoader_Registry::$sFilePath,
256 257
         AdminPageFrameworkLoader_Registry::HOOK_SLUG    // hook prefix
Please login to merge, or discard this patch.
development/factory/_abstract/utility/AdminPageFramework_Debug.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -51,7 +51,9 @@
 block discarded – undo
51 51
      */
52 52
     static public function get( $asArray, $sFilePath=null, $bEscape=true ) {
53 53
 
54
-        if ( $sFilePath ) self::log( $asArray, $sFilePath );     
54
+        if ( $sFilePath ) {
55
+            self::log( $asArray, $sFilePath );
56
+        }
55 57
         
56 58
         return $bEscape
57 59
             ? "<pre class='dump-array'>" . htmlspecialchars( self::getAsString( $asArray ) ) . "</pre>" // esc_html() has a bug that breaks with complex HTML code.
Please login to merge, or discard this patch.
factory/_abstract/utility/AdminPageFramework_RegisterClasses.php 1 patch
Braces   +6 added lines, -5 removed lines patch added patch discarded remove patch
@@ -137,7 +137,8 @@  discard block
 block discarded – undo
137 137
             $_aExcludeDirNames = ( array ) $aSearchOptions['exclude_dir_names'];
138 138
             $_bIsRecursive = $aSearchOptions[ 'is_recursive' ];
139 139
             
140
-            if ( defined( 'GLOB_BRACE' ) ) { // in some OSes this flag constant is not available.
140
+            if ( defined( 'GLOB_BRACE' ) ) {
141
+// in some OSes this flag constant is not available.
141 142
                 $_aFilePaths = $_bIsRecursive
142 143
                     ? $this->doRecursiveGlob( $sClassDirPath . '*.' . $this->_getGlobPatternExtensionPart( $_aAllowedExtensions ), GLOB_BRACE, $_aExcludeDirPaths, $_aExcludeDirNames )
143 144
                     : ( array ) glob( $sClassDirPath . '*.' . $this->_getGlobPatternExtensionPart( $_aAllowedExtensions ), GLOB_BRACE );
@@ -201,19 +202,19 @@  discard block
 block discarded – undo
201 202
         /**
202 203
          * Responds to the PHP auto-loader and includes the passed class based on the previously stored path associated with the class name in the constructor.
203 204
          */
204
-        public function _replyToAutoLoad_include( $sCalledUnknownClassName ) {            
205
+        public function _replyToAutoLoad_include( $sCalledUnknownClassName ) {
205 206
             if ( ! isset( $this->_aClasses[ $sCalledUnknownClassName ] ) ) { return; }
206 207
             include( $this->_aClasses[ $sCalledUnknownClassName ] );
207 208
         }
208
-        public function _replyToAutoLoad_include_once( $sCalledUnknownClassName ) {            
209
+        public function _replyToAutoLoad_include_once( $sCalledUnknownClassName ) {
209 210
             if ( ! isset( $this->_aClasses[ $sCalledUnknownClassName ] ) ) { return; }
210 211
             include_once( $this->_aClasses[ $sCalledUnknownClassName ] );
211 212
         }        
212
-        public function _replyToAutoLoad_require( $sCalledUnknownClassName ) {            
213
+        public function _replyToAutoLoad_require( $sCalledUnknownClassName ) {
213 214
             if ( ! isset( $this->_aClasses[ $sCalledUnknownClassName ] ) ) { return; }
214 215
             require( $this->_aClasses[ $sCalledUnknownClassName ] );
215 216
         }        
216
-        public function _replyToAutoLoad_require_once( $sCalledUnknownClassName ) {            
217
+        public function _replyToAutoLoad_require_once( $sCalledUnknownClassName ) {
217 218
             if ( ! isset( $this->_aClasses[ $sCalledUnknownClassName ] ) ) { return; }
218 219
             require_once( $this->_aClasses[ $sCalledUnknownClassName ] );
219 220
         } 
Please login to merge, or discard this patch.
factory/_abstract/utility/base_utility/AdminPageFramework_Utility_Array.php 1 patch
Braces   +8 added lines, -7 removed lines patch added patch discarded remove patch
@@ -122,7 +122,7 @@  discard block
 block discarded – undo
122 122
         
123 123
         $_aInvert = array();
124 124
         foreach( $aModel as $_isKey => $_v ) {
125
-            if ( array_key_exists( $_isKey, $aSubject ) ) { 
125
+            if ( array_key_exists( $_isKey, $aSubject ) ) {
126 126
                 continue; 
127 127
             }
128 128
             $_aInvert[ $_isKey ] = $_v;
@@ -172,11 +172,11 @@  discard block
 block discarded – undo
172 172
      */ 
173 173
     public static function uniteArraysRecursive( $aPrecedence, $aDefault ) {
174 174
                 
175
-        if ( is_null( $aPrecedence ) ) { 
175
+        if ( is_null( $aPrecedence ) ) {
176 176
             $aPrecedence = array(); 
177 177
         }
178 178
         
179
-        if ( ! is_array( $aDefault ) || ! is_array( $aPrecedence ) ) { 
179
+        if ( ! is_array( $aDefault ) || ! is_array( $aPrecedence ) ) {
180 180
             return $aPrecedence; 
181 181
         }
182 182
             
@@ -346,7 +346,8 @@  discard block
 block discarded – undo
346 346
         // array_key_exists( $_sKey, $aArray ) caused warnings in some occasions
347 347
         if ( isset( $aArray[ $_sKey ] ) ) {
348 348
             
349
-            if ( empty( $aKeys ) ) { // no more keys 
349
+            if ( empty( $aKeys ) ) {
350
+// no more keys 
350 351
                 return $aArray[ $_sKey ];
351 352
             }
352 353
             
@@ -473,7 +474,7 @@  discard block
 block discarded – undo
473 474
     static public function getReadableListOfArray( array $aArray ) {
474 475
         
475 476
         $_aOutput   = array();
476
-        foreach( $aArray as $_sKey => $_vValue ) {        
477
+        foreach( $aArray as $_sKey => $_vValue ) {
477 478
             $_aOutput[] = self::getReadableArrayContents( $_sKey, $_vValue, 32 ) . PHP_EOL;
478 479
         }
479 480
         return implode( PHP_EOL, $_aOutput );
@@ -529,7 +530,7 @@  discard block
 block discarded – undo
529 530
     static public function getReadableListOfArrayAsHTML( array $aArray ) {
530 531
 
531 532
         $_aOutput   = array();
532
-        foreach( $aArray as $_sKey => $_vValue ) {        
533
+        foreach( $aArray as $_sKey => $_vValue ) {
533 534
             $_aOutput[] = "<ul class='array-contents'>" 
534 535
                     .  self::getReadableArrayContentsHTML( $_sKey, $_vValue )
535 536
                 . "</ul>" . PHP_EOL;
@@ -562,7 +563,7 @@  discard block
 block discarded – undo
562 563
             }
563 564
             
564 565
             // Now it is a nested item.
565
-            foreach ( $vValue as $_sKey => $_vValue ) {   
566
+            foreach ( $vValue as $_sKey => $_vValue ) {
566 567
                 $_aOutput[] =  "<ul class='array-contents'>" 
567 568
                         . self::getReadableArrayContentsHTML( $_sKey, $_vValue ) 
568 569
                     . "</ul>";
Please login to merge, or discard this patch.
_abstract/utility/base_utility/AdminPageFramework_Utility_Deprecated.php 1 patch
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@
 block discarded – undo
32 32
      * @since       3.5.3           Moved from `AdminPageFramework_Utility_Array`.
33 33
      * @deprecated  3.5.3           Use `getElement()`. 
34 34
      */
35
-    public static function getCorrespondingArrayValue( $vSubject, $sKey, $sDefault='', $bBlankToDefault=false ) {    
35
+    public static function getCorrespondingArrayValue( $vSubject, $sKey, $sDefault='', $bBlankToDefault=false ) {
36 36
                 
37 37
         // If $vSubject is null,
38 38
         if ( ! isset( $vSubject ) ) { return $sDefault; }
Please login to merge, or discard this patch.
factory/_abstract/utility/base_utility/AdminPageFramework_Utility_Path.php 1 patch
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@
 block discarded – undo
73 73
         $aRedirectedFiles = ( array ) $asRedirectedFiles;
74 74
         $aRedirectedFiles[] = __FILE__;
75 75
         $_sCallerFilePath = '';
76
-        foreach( debug_backtrace() as $aDebugInfo )  {     
76
+        foreach( debug_backtrace() as $aDebugInfo ) {
77 77
             $_sCallerFilePath = $aDebugInfo['file'];
78 78
             if ( in_array( $_sCallerFilePath, $aRedirectedFiles ) ) { continue; }
79 79
             break; // catch the first found item.
Please login to merge, or discard this patch.
_abstract/utility/base_utility/AdminPageFramework_Utility_String.php 1 patch
Braces   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -58,13 +58,13 @@
 block discarded – undo
58 58
      */ 
59 59
     static public function fixNumber( $nToFix, $nDefault, $nMin='', $nMax='' ) {
60 60
 
61
-        if ( ! is_numeric( trim( $nToFix ) ) ) { 
61
+        if ( ! is_numeric( trim( $nToFix ) ) ) {
62 62
             return $nDefault; 
63 63
         }
64
-        if ( $nMin !== '' && $nToFix < $nMin ) { 
64
+        if ( $nMin !== '' && $nToFix < $nMin ) {
65 65
             return $nMin; 
66 66
         }
67
-        if ( $nMax !== '' && $nToFix > $nMax ) { 
67
+        if ( $nMax !== '' && $nToFix > $nMax ) {
68 68
             return $nMax; 
69 69
         }
70 70
         return $nToFix;
Please login to merge, or discard this patch.
factory/_abstract/utility/wp_utility/AdminPageFramework_WPUtility_File.php 1 patch
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -150,7 +150,7 @@  discard block
 block discarded – undo
150 150
             return false;
151 151
         }
152 152
 
153
-        if ( 200 != wp_remote_retrieve_response_code( $_aoResponse ) ){
153
+        if ( 200 != wp_remote_retrieve_response_code( $_aoResponse ) ) {
154 154
             unlink( $_sTmpFileName );
155 155
             return false;
156 156
         }
@@ -180,7 +180,7 @@  discard block
 block discarded – undo
180 180
         $_sDir = get_temp_dir();
181 181
         
182 182
         $sFilePath = basename( $sFilePath );
183
-        if ( empty( $sFilePath ) ) {            
183
+        if ( empty( $sFilePath ) ) {
184 184
             $sFilePath = time() . '.tmp';
185 185
         }
186 186
 
Please login to merge, or discard this patch.
factory/_abstract/utility/wp_utility/AdminPageFramework_WPUtility_Hook.php 1 patch
Braces   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -146,7 +146,7 @@  discard block
 block discarded – undo
146 146
      * 
147 147
      * @since       2.0.0
148 148
      */    
149
-    static public function addAndApplyFilters( /* $oCallerObject, $aFilters, $vInput, $vArgs... */ ) { 
149
+    static public function addAndApplyFilters( /* $oCallerObject, $aFilters, $vInput, $vArgs... */ ) {
150 150
             
151 151
         $_aArgs         = func_get_args();    
152 152
         // $oCallerObject  = $_aArgs[ 0 ];
@@ -183,14 +183,14 @@  discard block
 block discarded – undo
183 183
      * @param       mixed       $vData              The filtering data
184 184
      * @param       mixed       $vArgs              The arguments.
185 185
      */
186
-    static public function addAndApplyFilter( /* $oCallerObject, $sFilter, $vData, $vArgs... */ ) { 
186
+    static public function addAndApplyFilter( /* $oCallerObject, $sFilter, $vData, $vArgs... */ ) {
187 187
         
188 188
         // Parameters
189 189
         $_iArgs          = func_num_args();
190 190
         $_aArgs          = func_get_args();
191 191
         $_oCallerObject  = $_aArgs[ 0 ];
192 192
         $_sFilter        = $_aArgs[ 1 ];
193
-        if ( ! $_sFilter ) { 
193
+        if ( ! $_sFilter ) {
194 194
             return $_aArgs[ 2 ]; 
195 195
         }
196 196
         
Please login to merge, or discard this patch.