78% wp-easy-recipe

Code Review | WP EASY RECIPE

WordPress plugin WP EASY RECIPE scored78%from 54 tests.

About plugin

  • Plugin page: wp-easy-recipe
  • Plugin version: 1.6
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Jul 2, 2014
  • Latest release: Sep 27, 2023
  • Number of updates: 26
  • Update frequency: every 129.8 days
  • Top authors: india-web-developer (100%)

Code review

54 tests

User reviews

1 review

Install metrics

60+ active /5,006 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.10MB] [CPU: ▲4.07ms] Passed 4 tests

Analyzing server-side resources used by WP EASY RECIPE
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1144.59 ▼0.87
Dashboard /wp-admin3.41 ▲0.1160.36 ▲6.74
Posts /wp-admin/edit.php3.45 ▲0.0959.59 ▲12.93
Add New Post /wp-admin/post-new.php5.99 ▲0.1196.09 ▼1.86
Media Library /wp-admin/upload.php3.33 ▲0.1144.49 ▲12.28
Recipe Tips /wp-admin/edit.php?post_type=wp_easy_recipe_tips3.3643.08
Add New /wp-admin/post-new.php?post_type=wp_easy_recipe_tips3.4557.47
Recipes /wp-admin/edit.php?post_type=wp_easy_recipe3.3643.87
Recipe Categories /wp-admin/edit-tags.php?taxonomy=wp_easy_recipe_tax&post_type=wp_easy_recipe3.3546.71
Add New /wp-admin/post-new.php?post_type=wp_easy_recipe3.4555.60
Tags /wp-admin/edit-tags.php?taxonomy=post_tag&post_type=wp_easy_recipe3.3343.36
Settings /wp-admin/edit.php?post_type=wp_easy_recipe&page=wper-settings3.3040.25

Server storage [IO: ▲0.21MB] [DB: ▲0.00MB] Passed 3 tests

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 20 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for WP EASY RECIPE
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,969 ▲23413.65 ▼1.105.49 ▲2.5440.50 ▼3.38
Dashboard /wp-admin2,284 ▲965.82 ▲0.9894.29 ▼10.9138.66 ▼4.96
Posts /wp-admin/edit.php2,164 ▲752.06 ▲0.0435.99 ▼5.4835.05 ▲2.84
Add New Post /wp-admin/post-new.php1,584 ▲7023.17 ▲5.61663.02 ▼27.5638.33 ▼16.29
Media Library /wp-admin/upload.php1,470 ▲854.26 ▲0.0484.99 ▼27.3844.35 ▼2.02
Recipe Tips /wp-admin/edit.php?post_type=wp_easy_recipe_tips1,1282.0028.4730.10
Add New /wp-admin/post-new.php?post_type=wp_easy_recipe_tips2,2127.54168.8170.84
Recipes /wp-admin/edit.php?post_type=wp_easy_recipe1,1442.0028.9430.66
Recipe Categories /wp-admin/edit-tags.php?taxonomy=wp_easy_recipe_tax&post_type=wp_easy_recipe1,5853.1540.5727.96
Add New /wp-admin/post-new.php?post_type=wp_easy_recipe2,5387.79164.9556.31
Tags /wp-admin/edit-tags.php?taxonomy=post_tag&post_type=wp_easy_recipe1,3792.1825.3131.43
Settings /wp-admin/edit.php?post_type=wp_easy_recipe&page=wper-settings1,0711.6922.0632.38

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
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 take a closer look at the following
  • 6× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/wp-easy-recipe/lib/shortcode-list-page.php:75
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-easy-recipe/wp-easy-recipe.php:29
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_header() in wp-content/plugins/wp-easy-recipe/lib/templates/single-page-template.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_header() in wp-content/plugins/wp-easy-recipe/lib/templates/list-page-template.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-easy-recipe/lib/class-wp-easy-recipe.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/wp-easy-recipe/lib/recipe-slider.php:33

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
These are user-side errors you should fix
    • > GET request to /wp-admin/edit-tags.php?taxonomy=wp_easy_recipe_tax&post_type=wp_easy_recipe
    • > Console-api (warning) in unknown
    /wp-includes/js/jquery/jquery.min.js?ver=3.7.0 1:28609 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-admin/edit-tags.php?taxonomy=wp_easy_recipe_tax&post_type=wp_easy_recipe:296:21)\n at e (/wp-includes/js/jquery/jquery.min.js?ver=3.7.0:2:26990)\n at t (/wp-includes/js/jquery/jquery.min.js?ver=3.7.0:2:27292)" undefined
    • > GET request to /wp-admin/edit-tags.php?taxonomy=wp_easy_recipe_tax&post_type=wp_easy_recipe
    • > Javascript (severe) in unknown
    /wp-includes/js/jquery/jquery.min.js?ver=3.7.0 1:28721 Uncaught TypeError: $(...).live is not a function

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Please fix the following attributes: The official readme.txt is a good inspiration

wp-easy-recipe/wp-easy-recipe.php 92% from 13 tests

The main PHP file in "WP EASY RECIPE" ver. 1.6 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin2,356 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP62502041,180
JavaScript167464785
CSS35418391

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions43
▷ Named functions43100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
3 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
lib/images/controls.png1.46KB1.39KB▼ 4.30%
lib/images/drop_icon.png1.31KB0.36KB▼ 72.76%
lib/images/recipe_icon.png3.18KB2.33KB▼ 26.69%