68% buooy-sticky-header

Code Review | Buooy Sticky Header

WordPress plugin Buooy Sticky Header scored68%from 54 tests.

About plugin

  • Plugin page: buooy-sticky-header
  • Plugin version: 0.5.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8.1-3.9.1
  • WordPress version: 6.3.1
  • First release: Jun 4, 2014
  • Latest release: Jun 7, 2014
  • Number of updates: 4
  • Update frequency: every 0.8 days
  • Top authors: Buooy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,470 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.68MB] [CPU: ▼40.09ms] Passed 4 tests

An overview of server-side resources used by Buooy Sticky Header
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0641.35 ▲1.16
Dashboard /wp-admin3.26 ▼0.0415.31 ▼31.90
Posts /wp-admin/edit.php3.26 ▼0.1017.93 ▼27.81
Add New Post /wp-admin/post-new.php3.26 ▼2.6315.20 ▼84.96
Media Library /wp-admin/upload.php3.26 ▲0.0318.53 ▼15.67
Sticky Header /wp-admin/options-general.php?page=buooy-sticky-header3.2620.57

Server storage [IO: ▲6.68MB] [DB: ▲0.00MB] 67% from 3 tests

Filesystem and database footprint
Please fix the following
  • Illegal file modification detected: 1 file (0.00KB) outside of "wp-content/plugins/buooy-sticky-header/" and "wp-content/uploads/"
    • (new file) wp-content/redux/.empty
Filesystem: 425 new files
Database: no new tables, 8 new options
New WordPress options
can_compress_scripts
redux-framework-tracking
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
sticky_header

Browser metrics Passed 4 tests

This is an overview of browser requirements for Buooy Sticky Header
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,923 ▲18814.43 ▲0.0543.82 ▲42.0341.65 ▼21.92
Dashboard /wp-admin2,210 ▲225.86 ▲0.97102.18 ▲1.2040.22 ▼4.51
Posts /wp-admin/edit.php2,093 ▲42.05 ▲0.0436.77 ▼5.2133.07 ▼6.18
Add New Post /wp-admin/post-new.php1,526 ▲623.27 ▲0.02679.68 ▲1.4657.43 ▲0.03
Media Library /wp-admin/upload.php1,392 ▲74.22 ▲0.06108.58 ▲8.0847.53 ▲0.64
Sticky Header /wp-admin/options-general.php?page=buooy-sticky-header1,4994.0573.8841.21

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • This plugin did not uninstall without warnings or errors
    • > User deprecated in wp-includes/functions.php+5453
    Function get_currentuserinfo is deprecated since version 4.5.0! Use wp_get_current_user() instead.
  • Zombie WordPress options detected upon uninstall: 8 options
    • sticky_header
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • redux-framework-tracking
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/options-general.php?page=buooy-sticky-header
    • > User deprecated in wp-includes/functions.php+5453
    Function get_currentuserinfo is deprecated since version 4.5.0! Use wp_get_current_user() instead.
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=buooy-sticky-header
    • > Warning in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/redux-framework/ReduxCore/extensions/customizer/extension_customizer.php+368
    "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"?

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 17× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/options-sections.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/redux-extensions/loader.php:27
    • > PHP Fatal error
      Uncaught Error: Call to undefined function do_action_ref_array() in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/tgm/class-tgm-plugin-activation.php:174
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/redux-extensions/loader.php:27
    • > PHP Warning
      require(wp-content/plugins/buooy-sticky-header/admin/bootstrap.php): failed to open stream: No such file or directory in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/redux-framework/bootstrap_tests.php on line 27
    • > PHP Warning
      "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/redux-framework/ReduxCore/extensions/customizer/extension_customizer.php on line 368
    • > PHP Warning
      "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/redux-framework/ReduxCore/extensions/customizer/extension_customizer.php on line 349
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/redux-extensions/loader.php:27
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/redux-extensions/loader.php:27
    • > PHP Warning
      "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in wp-content/plugins/buooy-sticky-header/admin/includes/admin-folder/admin/redux-framework/ReduxCore/extensions/customizer/extension_customizer.php on line 337

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
  • Screenshots: These screenshots require images: #1 (Sticky Header smartly hides when you are at the top of your page), #2 (Set a specific pixel distance where Sticky Header will appear), #3 (Easily share and get more attention to your website/blog/news), #4 (Easy to use inituitive dashboard)
Please take inspiration from this readme.txt

buooy-sticky-header/buooy-sticky-header.php Passed 13 tests

The primary PHP file in "Buooy Sticky Header" version 0.5.2 is used by WordPress to initiate all plugin functionality
95 characters long description:
This plugin provides you with an sticky header that contains your post title and share buttons!

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin40,131 lines of code in 347 files:
LanguageFilesBlank linesComment linesLines of code
PHP883,4957,10113,161
JavaScript1472,5282,22111,428
JSON5005,026
CSS423832194,606
LESS302981203,419
Sass25301,140
Markdown62530837
SVG100309
XML11090
HTML18060
Bourne Shell124055

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.58
Average class complexity34.46
▷ Minimum class complexity1.00
▷ Maximum class complexity762.00
Average method complexity6.55
▷ Minimum method complexity1.00
▷ Maximum method complexity95.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes76
▷ Abstract classes00.00%
▷ Concrete classes76100.00%
▷ Final classes00.00%
Methods458
▷ Static methods429.17%
▷ Public methods42793.23%
▷ Protected methods61.31%
▷ Private methods255.46%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants133.33%
▷ Class constants266.67%
▷ Public constants2100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
49 PNG files occupy 0.96MB with 0.19MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/includes/admin-folder/admin/redux-framework/ReduxCore/assets/css/vendor/jquery-ui-bootstrap/images/ui-bg_glass_75_dadada_1x400.png0.11KB0.16KB0.00%
admin/includes/admin-folder/admin/redux-framework/ReduxCore/assets/css/vendor/jquery-ui-bootstrap/images/ui-bg_glass_75_e6e6e6_1x400.png0.11KB0.14KB0.00%
admin/includes/admin-folder/admin/redux-framework/ReduxCore/assets/img/toggle_tabs.png0.35KB0.35KB0.00%
admin/includes/admin-folder/admin/redux-framework/ReduxCore/assets/css/vendor/jquery-ui-bootstrap/images/ui-icons_ffffff_256x240.png4.27KB4.11KB▼ 3.78%
admin/includes/admin-folder/admin/redux-framework/ReduxCore/assets/img/1col.png2.83KB0.14KB▼ 95.13%