68% zip-recipes

Code Review | Recipe Maker For Your Food Blog from Zip Recipes

WordPress plugin Recipe Maker For Your Food Blog from Zip Recipes scored68%from 54 tests.

About plugin

  • Plugin page: zip-recipes
  • Plugin version: 8.1.1
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.3
  • WordPress version: 6.3.1
  • First release: Dec 7, 2014
  • Latest release: Oct 30, 2023
  • Number of updates: 289
  • Update frequency: every 11.3 days
  • Top authors: RogierLankhorst (52.6%)hgezim (47.06%)hesseldejong (1.04%)

Code review

54 tests

User reviews

94 reviews

Install metrics

3,000+ active /230,807 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

Server metrics [RAM: ▲1.50MB] [CPU: ▲5.72ms] Passed 4 tests

An overview of server-side resources used by Recipe Maker For Your Food Blog from Zip Recipes
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /4.73 ▲1.2748.69 ▲11.48
Dashboard /wp-admin4.89 ▲1.5462.04 ▲0.53
Posts /wp-admin/edit.php5.11 ▲1.7583.17 ▲36.32
Add New Post /wp-admin/post-new.php7.50 ▲1.6194.01 ▼2.01
Media Library /wp-admin/upload.php4.81 ▲1.5846.44 ▲12.88
Template /wp-admin/admin.php?page=zrdn-template5.39105.14
Recipes /wp-admin/admin.php?page=zrdn-recipes5.0392.83
Settings /wp-admin/admin.php?page=zrdn-settings5.0270.13

Server storage [IO: ▲8.52MB] [DB: ▲0.01MB] Passed 3 tests

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 324 new files
Database: 1 new table, 35 new options
New tables
wp_amd_zlrecipe_recipes
New WordPress options
db_upgraded
widget_recent-comments
zrdn_activated_once
zrdn_settings_nutrition
zrdn_settings_print
zrdn_settings_nutrition_label
widget_recent-posts
widget_zrdn_nutrition_widget
zrdn_settings_actions
widget_theysaidso_widget
...

Browser metrics Passed 4 tests

This is an overview of browser requirements for Recipe Maker For Your Food Blog from Zip Recipes
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,929 ▲15813.34 ▼0.967.94 ▲6.2141.42 ▼2.05
Dashboard /wp-admin2,247 ▲705.57 ▼0.1095.38 ▲9.0574.97 ▲36.35
Posts /wp-admin/edit.php2,178 ▲782.03 ▲0.0133.83 ▼5.2933.44 ▼2.83
Add New Post /wp-admin/post-new.php6,223 ▲4,69719.87 ▼3.691,025.80 ▲363.3339.94 ▼28.69
Media Library /wp-admin/upload.php1,486 ▲834.20 ▲0.02101.14 ▼4.4474.59 ▲31.29
Template /wp-admin/admin.php?page=zrdn-template4,57311.54408.56118.70
Recipes /wp-admin/admin.php?page=zrdn-recipes1,3422.2366.6645.09
Settings /wp-admin/admin.php?page=zrdn-settings1,8994.6184.3774.99

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • Zombie tables detected upon uninstall: 1 table
    • wp_amd_zlrecipe_recipes
  • This plugin did not uninstall successfully, leaving 35 options in the database
    • zrdn_activated_once
    • zrdn_settings_advanced
    • zrdn_settings_authors
    • zrdn_settings_image
    • zrdn-current-version
    • wp_calendar_block_has_published_posts
    • zrdn_default_addons_enabled
    • zrdn_recipe_blocks_layout
    • zrdn_settings_labels
    • zrdn_settings_nutrition
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 24× PHP files output non-empty strings when accessed directly via GET requests (only 10 are shown):
    • > /wp-content/plugins/zip-recipes/NutritionLabel/NutritionLabel.php
    • > /wp-content/plugins/zip-recipes/views/recipe_title.php
    • > /wp-content/plugins/zip-recipes/grid/grid-enqueue.php
    • > /wp-content/plugins/zip-recipes/views/extension-grid.php
    • > /wp-content/plugins/zip-recipes/views/block_wrap.php
    • > /wp-content/plugins/zip-recipes/views/jsonld.php
    • > /wp-content/plugins/zip-recipes/grid/templates/recipe-block-element.php
    • > /wp-content/plugins/zip-recipes/views/nutrition-label.php
    • > /wp-content/plugins/zip-recipes/NutritionLabel/class-shortcode.php
    • > /wp-content/plugins/zip-recipes/sharing/class-recipe-sharing-admin.php
  • 71× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Notice
      Undefined variable: recipe in wp-content/plugins/zip-recipes/views/recipe_image.php on line 7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function ZRDN\\add_filter() in wp-content/plugins/zip-recipes/plugins/base.php:19
    • > PHP Notice
      Trying to get property 'is_featured_post_image' of non-object in wp-content/plugins/zip-recipes/views/recipe_image.php on line 2
    • > PHP Fatal error
      Uncaught Error: Class 'ZRDN\\ZipRecipes' not found in wp-content/plugins/zip-recipes/views/template_settings.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/zip-recipes/views/about_extensions.php:3
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/zip-recipes/views/permalink.php on line 1
    • > PHP Fatal error
      Uncaught Error: Class 'WP_REST_Controller' not found in wp-content/plugins/zip-recipes/plugins/RecipeGrid2/api.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/zip-recipes/views/category.php:1
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/zip-recipes/views/recipe.php on line 66
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/zip-recipes/NutritionLabel/widget.php:7

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: recipes, cooking, blog, seo, recipe...

zip-recipes/zip-recipes.php Passed 13 tests

Analyzing the main PHP file in "Recipe Maker For Your Food Blog from Zip Recipes" version 8.1.1
110 characters long description:
A plugin that adds all the necessary microdata to your recipes, so they will show up in Google's Recipe Search

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Success! There were no dangerous files found in this plugin36,050 lines of code in 268 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript1223,7674,11615,987
PHP701,8802,0669,634
CSS346312606,543
LESS115191712,995
Markdown22340480
JSON100192
SVG2420177
Sass412042

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.45
Average class complexity65.93
▷ Minimum class complexity1.00
▷ Maximum class complexity187.00
Average method complexity4.56
▷ Minimum method complexity1.00
▷ Maximum method complexity49.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes15
▷ Abstract classes16.67%
▷ Concrete classes1493.33%
▷ Final classes00.00%
Methods272
▷ Static methods10839.71%
▷ Public methods25995.22%
▷ Protected methods10.37%
▷ Private methods124.41%
Functions53
▷ Named functions4788.68%
▷ Anonymous functions611.32%
Constants16
▷ Global constants956.25%
▷ Class constants743.75%
▷ Public constants7100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
19 PNG files occupy 2.14MB with 0.52MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/recipe-preview.png138.67KB51.55KB▼ 62.83%
images/zip-recipes-icon-16.png0.99KB0.92KB▼ 7.30%
images/logo.png2.63KB2.63KB0.19%
images/zip-recipes-placeholder.png15.34KB7.62KB▼ 50.32%
images/really-simple-pluginsx.png2.17KB2.16KB0.23%