90% love-button

Code Review | Love/Like/Upvote Button

WordPress plugin Love/Like/Upvote Button scored90%from 54 tests.

About plugin

  • Plugin page: love-button
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Feb 15, 2013
  • Latest release: Aug 19, 2023
  • Number of updates: 35
  • Update frequency: every 109.6 days
  • Top authors: Pantaloon (88.57%)bhadaway (14.29%)

Code review

54 tests

User reviews

5 reviews

Install metrics

80+ active /5,632 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

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

Analyzing server-side resources used by Love/Like/Upvote Button
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0141.15 ▲2.35
Dashboard /wp-admin3.35 ▼0.0356.38 ▼7.76
Posts /wp-admin/edit.php3.40 ▲0.0148.69 ▼2.54
Add New Post /wp-admin/post-new.php5.93 ▲0.0188.16 ▼24.51
Media Library /wp-admin/upload.php3.28 ▲0.0139.45 ▲2.99

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Love/Like/Upvote Button
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5414.46 ▲0.106.15 ▲4.1544.82 ▲1.61
Dashboard /wp-admin2,198 ▲215.62 ▼0.0196.74 ▲10.0542.81 ▼2.41
Posts /wp-admin/edit.php2,103 ▲31.98 ▼0.0134.63 ▼3.7831.73 ▼4.47
Add New Post /wp-admin/post-new.php1,528 ▼023.16 ▼0.14681.49 ▲2.2858.84 ▲6.31
Media Library /wp-admin/upload.php1,400 ▼34.11 ▼0.07109.90 ▲0.7947.76 ▼1.16

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments

Smoke tests Passed 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 Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
7 plugin tags: twitter, vote, love, button, like...

love-button/love.php 92% from 13 tests

This is the main PHP file of "Love/Like/Upvote Button" version 0.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: Please rename the main PHP file in this plugin to the plugin slug ("love-button.php" instead of "love.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
There were no executable files found in this plugin34 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP141132
CSS1001
JavaScript1001

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.17
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%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
No PNG files were detected