89% default-posts-slider-addon

Code Review | Default Post Slider Addon

WordPress plugin Default Post Slider Addon scored89%from 54 tests.

About plugin

  • Plugin page: default-posts-sli...
  • Plugin version: 1.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.2
  • WordPress version: 6.3.1
  • First release: Oct 7, 2023
  • Latest release: Oct 7, 2023
  • Number of updates: 2
  • Update frequency: every 5.5 days
  • Top authors: vaibhav31gangrade (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /23 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

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

A check of server-side resources used by Default Post Slider Addon
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0042.53 ▲2.04
Dashboard /wp-admin3.31 ▲0.0050.55 ▼5.10
Posts /wp-admin/edit.php3.36 ▲0.0045.85 ▼9.74
Add New Post /wp-admin/post-new.php5.89 ▲0.0084.82 ▼15.46
Media Library /wp-admin/upload.php3.23 ▲0.0033.28 ▼0.47

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Default Post Slider Addon
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.16 ▼1.062.02 ▼0.0544.74 ▼1.12
Dashboard /wp-admin2,203 ▲155.77 ▲0.8894.92 ▼14.9339.09 ▼6.08
Posts /wp-admin/edit.php2,086 ▼32.05 ▲0.0038.22 ▼3.6932.76 ▼4.28
Add New Post /wp-admin/post-new.php1,533 ▲1423.32 ▲0.16677.46 ▲15.3661.14 ▲8.37
Media Library /wp-admin/upload.php1,385 ▼34.21 ▲0.02105.08 ▲0.4646.39 ▲1.64

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes:
  • Screenshots: Please add an image for screenshot #2 (This is the second screen shot)
  • Donate link: Invalid url: ""
The official readme.txt is a good inspiration

default-posts-slider-addon/addon.php 92% from 13 tests

The entry point to "Default Post Slider Addon" version 1.0 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("default-posts-slider-addon.php" instead of "addon.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected62 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2151362

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.20
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods480.00%
▷ Protected methods120.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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.17MB with 0.12MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot/Screenshot.png175.01KB48.57KB▼ 72.25%