74% managed-posts-rating-like-button

Code Review | Managed posts rating ★ Like button

WordPress plugin Managed posts rating ★ Like button scored74%from 54 tests.

About plugin

  • Plugin page: managed-posts-rat...
  • Plugin version: 2.0.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.3
  • WordPress version: 6.3.1
  • First release: Mar 29, 2023
  • Latest release: Aug 15, 2023
  • Number of updates: 11
  • Update frequency: every 12.6 days
  • Top authors: levenyatko (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /232 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.27MB] [CPU: ▼0.19ms] Passed 4 tests

Analyzing server-side resources used by Managed posts rating ★ Like button
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1245.99 ▼1.42
Dashboard /wp-admin3.69 ▲0.3856.38 ▲2.11
Posts /wp-admin/edit.php3.74 ▲0.3850.20 ▼2.02
Add New Post /wp-admin/post-new.php6.16 ▲0.27119.02 ▲25.67
Media Library /wp-admin/upload.php3.55 ▲0.3141.01 ▲0.58
Statistic /wp-admin/admin.php?page=mpr-stat-page3.5238.56
Logs /wp-admin/admin.php?page=mpr-plugin-page3.5538.23
Settings /wp-admin/admin.php?page=mpr-plugin-settings3.5136.20

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 36 new files
Database: 1 new table, 7 new options
New tables
wp_mpr_rating_log
New WordPress options
db_upgraded
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
mpr_general_section

Browser metrics Passed 4 tests

A check of browser resources used by Managed posts rating ★ Like button
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,827 ▲6614.24 ▼0.522.19 ▲0.1544.29 ▼6.85
Dashboard /wp-admin2,229 ▲495.65 ▲0.0293.35 ▲1.4743.51 ▲0.96
Posts /wp-admin/edit.php2,170 ▲731.99 ▼0.0437.60 ▼4.1735.72 ▲0.55
Add New Post /wp-admin/post-new.php1,720 ▲19221.90 ▼1.12613.70 ▼71.6458.99 ▲5.77
Media Library /wp-admin/upload.php1,431 ▲284.17 ▼0.1098.39 ▼14.2040.48 ▼4.78
Statistic /wp-admin/admin.php?page=mpr-stat-page8854.04120.7830.66
Logs /wp-admin/admin.php?page=mpr-plugin-page1,0302.0231.5728.92
Settings /wp-admin/admin.php?page=mpr-plugin-settings9822.0028.5629.27

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • The uninstall procedure failed, leaving 1 table in the database
    • wp_mpr_rating_log
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • mpr_general_section
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 75% 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 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/managed-posts-rating-like-button/includes/functions.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 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
5 plugin tags: rating system, rate post, rating, voting, like button

managed-posts-rating-like-button/managed-posts-rating-like-button.php 85% from 13 tests

The principal PHP file in "Managed posts rating ★ Like button" v. 2.0.0 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Requires PHP: Required version does not match the one declared in readme.txt ("7.4" instead of "7.2")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
There were no executable files found in this plugin2,334 lines of code in 34 files:
LanguageFilesBlank linesComment linesLines of code
PHP275881052,058
CSS3263152
JavaScript42911124

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity10.39
▷ Minimum class complexity1.00
▷ Maximum class complexity27.00
Average method complexity2.44
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces5
Interfaces0
Traits0
Classes18
▷ Abstract classes15.56%
▷ Concrete classes1794.44%
▷ Final classes15.88%
Methods107
▷ Static methods1312.15%
▷ Public methods9084.11%
▷ Protected methods76.54%
▷ Private methods109.35%
Functions23
▷ Named functions1773.91%
▷ Anonymous functions626.09%
Constants3
▷ Global constants3100.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 were not PNG files found in your plugin