78% wonka-slide

Code Review | Wonka Slide

WordPress plugin Wonka Slidescored78%from 54 tests.

About plugin

  • Plugin page: wonka-slide
  • Plugin version: 1.3.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-5.3.2
  • WordPress version: 6.3.1
  • First release: Dec 22, 2017
  • Latest release: Jan 20, 2020
  • Number of updates: 26
  • Update frequency: every 29.2 days
  • Top authors: mrlister1 (53.85%)llister (50%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /888 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.08MB] [CPU: ▼4.13ms] Passed 4 tests

Server-side resources used by Wonka Slide
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0744.57 ▲1.79
Dashboard /wp-admin3.38 ▲0.0749.95 ▼1.39
Posts /wp-admin/edit.php3.49 ▲0.1347.40 ▼0.76
Add New Post /wp-admin/post-new.php5.98 ▲0.0984.47 ▼14.72
Media Library /wp-admin/upload.php3.30 ▲0.0736.24 ▲0.35

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 32 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Wonka Slide
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,912 ▲12613.44 ▼0.919.33 ▲7.5638.69 ▼6.29
Dashboard /wp-admin2,235 ▲555.58 ▼0.0597.04 ▲11.1371.92 ▲28.98
Posts /wp-admin/edit.php2,137 ▲371.98 ▼0.0035.48 ▼4.2433.38 ▲1.34
Add New Post /wp-admin/post-new.php1,560 ▲3423.50 ▲0.37766.85 ▲69.2055.58 ▲3.37
Media Library /wp-admin/upload.php1,440 ▲404.11 ▲0.04100.94 ▼10.2061.91 ▲12.69

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options

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
Good news, no errors were detected

SRP 0% 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
  • 2× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/wonka-slide/public/partials/wonka-slide-public-display.php
    • > /wp-content/plugins/wonka-slide/admin/class-wonka-slide-build.php
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/wonka-slide/admin/partials/wonka-slide-admin-display.php:19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/wonka-slide/admin/partials/wonka-slide-add-action-links.php:23

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 81% 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
These attributes need your attention:
  • Requires php: Version not formatted correctly
  • Plugin Name: You should set the name of your plugin on the first line ( === Wonka Slide=== )
  • Screenshots: Add a description for screenshot #2 in wonka-slide/assets to your readme.txt
You can take inspiration from this readme.txt

wonka-slide/wonka-slide.php Passed 13 tests

The entry point to "Wonka Slide" version 1.3.3 is a PHP file that has certain tags in its header comment area
105 characters long description:
Wonka Slide is a plugin that was built to run a lean Slider that is made up of the Posts featured images.

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
No dangerous file extensions were detected782 lines of code in 24 files:
LanguageFilesBlank linesComment linesLines of code
PHP14144578333
Sass282267
JavaScript31529143
CSS22936
SVG3003

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity1.57
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.15
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods26
▷ Static methods27.69%
▷ Public methods2180.77%
▷ Protected methods00.00%
▷ Private methods519.23%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.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
There are no PNG files in this plugin