84% bunny-companion

Code Review | Bunny Companion

WordPress plugin Bunny Companion scored84%from 54 tests.

About plugin

  • Plugin page: bunny-companion
  • Plugin version: 1.0.6
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3
  • WordPress version: 6.3.1
  • First release: Jan 28, 2023
  • Latest release: Sep 17, 2023
  • Number of updates: 16
  • Update frequency: every 14.6 days
  • Top authors: bunnythemes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

1,000+ active /6,712 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼9.96ms] Passed 4 tests

This is a short check of server-side resources used by Bunny Companion
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0040.68 ▼4.18
Dashboard /wp-admin3.31 ▲0.0146.93 ▼5.83
Posts /wp-admin/edit.php3.36 ▲0.0046.96 ▼4.01
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.01 ▼25.80
Media Library /wp-admin/upload.php3.23 ▲0.0040.27 ▲3.33

Server storage [IO: ▲1.42MB] [DB: ▲0.07MB] Passed 3 tests

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 75 new files
Database: no new tables, 7 new options
New WordPress options
item_details_page
can_compress_scripts
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

Bunny Companion: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.27 ▼0.141.73 ▼0.0942.30 ▲1.49
Dashboard /wp-admin2,192 ▲125.63 ▲0.0991.23 ▼1.2942.44 ▼1.88
Posts /wp-admin/edit.php2,103 ▲32.02 ▲0.0039.91 ▲1.0934.55 ▼4.22
Add New Post /wp-admin/post-new.php1,528 ▼623.05 ▲0.08667.54 ▲47.0354.28 ▼12.54
Media Library /wp-admin/upload.php1,394 ▼34.19 ▼0.11101.69 ▲2.1347.67 ▲5.08

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • The uninstall procedure has failed, leaving 7 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • item_details_page
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 64× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bunny-companion/inc/themes/fasterly/features/typography.php:327
    • > PHP Fatal error
      require(): Failed opening required 'BUNNY_COMPANION_PLUGIN_DIRinc/themes/fasterly/features/slider.php' (include_path='.:/usr/share/php') in wp-content/plugins/bunny-companion/inc/themes/fasco/fasco.php on line 17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bunny-companion/inc/themes/bunnypress/features/service.php:252
    • > PHP Warning
      require(BUNNY_COMPANION_PLUGIN_DIRinc/themes/bunnypress/features/header.php): failed to open stream: No such file or directory in wp-content/plugins/bunny-companion/inc/themes/easify/easify.php on line 15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/bunny-companion/bunny-companion.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bunny-companion/inc/themes/bunify/features/header.php:87
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_theme_mod() in wp-content/plugins/bunny-companion/inc/themes/bunify/sections/index-information.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bunny-companion/inc/themes/fasterly/features/cta.php:365
    • > PHP Warning
      Use of undefined constant BUNNY_COMPANION_PLUGIN_DIR - assumed 'BUNNY_COMPANION_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/bunny-companion/inc/themes/smoothify/smoothify.php on line 18
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bunny-companion/inc/themes/fasterly/features/information.php:216

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
3 plugin tags: demo, homepage, sections

bunny-companion/bunny-companion.php Passed 13 tests

The entry point to "Bunny Companion" version 1.0.6 is a PHP file that has certain tags in its header comment area
111 characters long description:
This is a plugin created for Bunny themes. This plugin provides additional frontpage sections for Bunny Themes.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected6,617 lines of code in 52 files:
LanguageFilesBlank linesComment linesLines of code
PHP525625096,617

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity1.62
▷ Minimum class complexity1.00
▷ Maximum class complexity9.00
Average method complexity1.62
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes13
▷ Abstract classes00.00%
▷ Concrete classes13100.00%
▷ Final classes00.00%
Methods13
▷ Static methods17.69%
▷ Public methods13100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions95
▷ Named functions95100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
11 PNG files occupy 0.20MB with 0.11MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
inc/themes/fasterly/assets/images/footer-logo.png18.63KB1.11KB▼ 94.06%
inc/themes/easify/assets/images/logo.png2.90KB1.78KB▼ 38.46%
inc/themes/smoothify/assets/images/logo.png21.26KB2.88KB▼ 86.46%
inc/themes/smoothify/assets/images/info/info-2-bg.png2.22KB1.22KB▼ 45.25%
inc/themes/smoothify/assets/images/bg_pattern_14.png7.92KB7.92KB0.00%