68% ripple-by-wowmotion

Code Review | Ripple

WordPress plugin Ripple scored68%from 54 tests.

About plugin

  • Plugin page: ripple-by-wowmotion
  • Plugin version: 1.5.5
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.2
  • WordPress version: 6.3.1
  • First release: Dec 29, 2016
  • Latest release: May 24, 2019
  • Number of updates: 34
  • Update frequency: every 25.6 days
  • Top authors: c.laborier (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,375 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.39MB] [CPU: ▼2.15ms] Passed 4 tests

This is a short check of server-side resources used by Ripple
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.88 ▲0.4252.56 ▲8.12
Dashboard /wp-admin3.73 ▲0.4252.35 ▼0.74
Posts /wp-admin/edit.php3.78 ▲0.4253.02 ▲1.32
Add New Post /wp-admin/post-new.php6.25 ▲0.3691.39 ▼10.28
Media Library /wp-admin/upload.php3.59 ▲0.3639.59 ▲1.12
Dashboard /wp-admin/admin.php?page=ripple_admin3.5649.95
Breadcrumbs /wp-admin/admin.php?page=ripple_breadcrumbs3.5738.88
Hierarchical related content /wp-admin/admin.php?page=ripple_hierarchical_related_content3.5836.21
Semantic related content /wp-admin/admin.php?page=ripple_semantic_related_content3.6040.56

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 40 new files
Database: no new tables, 11 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
widget_recent-posts
ripple_admin
theysaidso_admin_options
ripple_breadcrumbs
ripple_hierarchical_related_content
ripple_options
widget_recent-comments
ripple_semantic_related_content
...

Browser metrics Passed 4 tests

An overview of browser requirements for Ripple
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,860 ▲9913.22 ▼1.211.67 ▼0.2043.29 ▲2.81
Dashboard /wp-admin2,261 ▲554.86 ▼0.0399.86 ▼6.7637.21 ▼2.77
Posts /wp-admin/edit.php2,137 ▲582.01 ▼0.0236.60 ▲0.1432.51 ▼7.62
Add New Post /wp-admin/post-new.php1,570 ▲1322.89 ▼0.25612.17 ▼67.2257.73 ▼3.58
Media Library /wp-admin/upload.php1,440 ▲404.20 ▼0.06101.35 ▼3.7548.01 ▲1.33
Dashboard /wp-admin/admin.php?page=ripple_admin1,1592.3641.9750.04
Breadcrumbs /wp-admin/admin.php?page=ripple_breadcrumbs1,0732.1133.2457.06
Hierarchical related content /wp-admin/admin.php?page=ripple_hierarchical_related_content1,3912.1229.2848.79
Semantic related content /wp-admin/admin.php?page=ripple_semantic_related_content1,5902.1336.3451.23

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • The plugin did not uninstall gracefully
    • > Warning in wp-includes/class-wp-hook.php+310
    call_user_func_array() expects parameter 1 to be a valid callback, class 'RippleAdmin' does not have a method ''ripple_on_deactivate'
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% 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
Please fix the following
  • 18× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      require_once(): Failed opening required 'RIPPLE_DIR_PATH/admin/class/class.admin-options-manager.php' (include_path='.:/usr/share/php') in wp-content/plugins/ripple-by-wowmotion/admin/class/class.admin-initializer.php on line 2
    • > PHP Warning
      require_once(RIPPLE_DIR_PATH/admin/class/class.admin-options-manager.php): failed to open stream: No such file or directory in wp-content/plugins/ripple-by-wowmotion/admin/admin.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'RippleBreadcrumbWidget' not found in wp-content/plugins/ripple-by-wowmotion/admin/partials/_help_breadcrumbs_widget_shortcode.html.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function checked() in wp-content/plugins/ripple-by-wowmotion/admin/partials/_subform_excerpt.html.php:4
    • > PHP Fatal error
      require_once(): Failed opening required 'RIPPLE_DIR_PATH/admin/class/class.admin-options-manager.php' (include_path='.:/usr/share/php') in wp-content/plugins/ripple-by-wowmotion/functions.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/ripple-by-wowmotion/config.php:11
    • > PHP Warning
      require_once(RIPPLE_DIR_PATH/admin/class/class.admin-options-manager.php): failed to open stream: No such file or directory in wp-content/plugins/ripple-by-wowmotion/admin/class/class.admin-initializer.php on line 2
    • > PHP Warning
      require_once(RIPPLE_DIR_PATH/admin/class/class.admin-options-manager.php): failed to open stream: No such file or directory in wp-content/plugins/ripple-by-wowmotion/functions.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'RippleSemanticRelatedContentWidget' not found in wp-content/plugins/ripple-by-wowmotion/admin/partials/_help_semantic_widget_shortcode.html.php:3
    • > PHP Fatal error
      require_once(): Failed opening required 'RIPPLE_DIR_PATH/includes/class.ripple-helper.php' (include_path='.:/usr/share/php') in wp-content/plugins/ripple-by-wowmotion/includes/class.ripple-middleware.php on line 3

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Please take a look at the following user-side issues
    • > GET request to /wp-admin/admin.php?page=ripple_admin
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28609 "jQuery.Deferred exception: \"undefined\" is not valid JSON" "SyntaxError: \"undefined\" is not valid JSON\n at parse (\u003Canonymous>)\n at Function.\u003Canonymous> (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:5:3161)\n at e.\u003Ccomputed> [as parseJSON] (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:5:1582)\n at Object.initialize (/wp-content/plugins/ripple-by-wowmotion/admin/js/admin.js?ver=0.1.0:8:28)\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/ripple-by-wowmotion/admin/js/admin.js?ver=0.1.0:132:31)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:27292)" undefined
    • > GET request to /wp-admin/admin.php?page=ripple_admin
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 4:3160 Uncaught SyntaxError: "undefined" is not valid JSON

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes: You can take inspiration from this readme.txt

ripple-by-wowmotion/ripple.php 92% from 13 tests

The main PHP script in "Ripple" version 1.5.5 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("ripple-by-wowmotion.php" instead of "ripple.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin2,907 lines of code in 37 files:
LanguageFilesBlank linesComment linesLines of code
PHP265127792,397
CSS99635341
JavaScript24748169

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity10.67
▷ Minimum class complexity1.00
▷ Maximum class complexity42.00
Average method complexity2.76
▷ Minimum method complexity1.00
▷ Maximum method complexity23.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes18
▷ Abstract classes211.11%
▷ Concrete classes1688.89%
▷ Final classes00.00%
Methods99
▷ Static methods1414.14%
▷ Public methods7272.73%
▷ Protected methods11.01%
▷ Private methods2626.26%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants11
▷ Global constants545.45%
▷ Class constants654.55%
▷ Public constants6100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
admin/img/speech-bubble-24-120.png3.42KB2.49KB▼ 27.02%