83% dislike

Code Review | Dislike

WordPress plugin Dislike scored83%from 54 tests.

About plugin

  • Plugin page: dislike
  • Plugin version: 1.1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.0
  • WordPress version: 6.3.1
  • First release: Jan 14, 2013
  • Latest release: Nov 3, 2014
  • Number of updates: 11
  • Update frequency: every 59.9 days
  • Top authors: ROCKIT-INTERNET (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,209 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼2.41ms] Passed 4 tests

Analyzing server-side resources used by Dislike
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0243.81 ▼1.59
Dashboard /wp-admin3.32 ▲0.0250.13 ▼4.07
Posts /wp-admin/edit.php3.38 ▲0.0247.46 ▼1.73
Add New Post /wp-admin/post-new.php5.91 ▲0.0292.08 ▼2.23
Media Library /wp-admin/upload.php3.25 ▲0.0238.79 ▲1.81
Dislike /wp-admin/options-general.php?page=dislike/rockit-dislike.php3.2244.05

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 7 new files
Database: no new tables, 14 new options
New WordPress options
widget_recent-comments
dislike_exclude
dislike_window_width
can_compress_scripts
widget_recent-posts
dislike_content
dislike_window_height
dislike_text
dislike_url
dislike_show
...

Browser metrics Passed 4 tests

Checking browser requirements for Dislike
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,810 ▲6413.61 ▼0.765.10 ▲3.1144.06 ▼3.99
Dashboard /wp-admin2,213 ▲255.91 ▲0.02110.54 ▲7.2642.38 ▼4.30
Posts /wp-admin/edit.php2,090 ▲12.06 ▲0.0036.56 ▲1.8132.56 ▼7.82
Add New Post /wp-admin/post-new.php1,517 ▲317.70 ▲0.17668.29 ▲12.8061.61 ▲7.67
Media Library /wp-admin/upload.php1,395 ▲44.22 ▲0.00103.12 ▼1.5941.66 ▼2.63
Dislike /wp-admin/options-general.php?page=dislike/rockit-dislike.php9562.1724.2529.12

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 14 options in the database
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • dislike_archive
    • dislike_text
    • widget_theysaidso_widget
    • dislike_window_height
    • widget_recent-posts
    • dislike_window_width
    • widget_recent-comments
    • ...

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
Even though everything seems fine, this is not an exhaustive test

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
The following issues need your attention
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/dislike/rockit-dislike-admin.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/dislike/rockit-dislike.php:15

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 90% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
8 plugin tags: facebook, dislikebutton, dislike, like-button, dislike-button...

dislike/rockit-dislike.php 77% from 13 tests

This is the main PHP file of "Dislike" version 1.1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("dislike.php" instead of "rockit-dislike.php")
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 175 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin309 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP24730220
PO File1306689

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There were not PNG files found in your plugin