84% love-me

Code Review | Love Me

WordPress plugin Love Me scored84%from 54 tests.

About plugin

  • Plugin page: love-me
  • Plugin version: 1.1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-5.9
  • WordPress version: 6.3.1
  • First release: Nov 27, 2017
  • Latest release: Jan 26, 2022
  • Number of updates: 5
  • Update frequency: every 307.2 days
  • Top authors: leprincenoir (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

400+ active /5,491 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.10MB] [CPU: ▼6.97ms] Passed 4 tests

A check of server-side resources used by Love Me
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.0937.02 ▼7.34
Dashboard /wp-admin3.40 ▲0.0947.15 ▼0.91
Posts /wp-admin/edit.php3.51 ▲0.1547.84 ▼4.13
Add New Post /wp-admin/post-new.php6.00 ▲0.1187.19 ▼14.44
Media Library /wp-admin/upload.php3.32 ▲0.0936.83 ▼1.98
Love me /wp-admin/options-general.php?page=love_me_options3.2933.98

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Love Me
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,879 ▲11813.78 ▼0.608.11 ▲6.2742.53 ▼0.28
Dashboard /wp-admin2,202 ▲255.63 ▲0.1088.10 ▼2.1342.65 ▼3.34
Posts /wp-admin/edit.php2,104 ▲42.04 ▲0.0335.14 ▼8.8538.61 ▼1.85
Add New Post /wp-admin/post-new.php1,533 ▲522.86 ▼0.64639.52 ▼38.9546.31 ▼15.51
Media Library /wp-admin/upload.php1,404 ▲14.12 ▼0.05123.43 ▲19.2446.52 ▲1.45
Love me /wp-admin/options-general.php?page=love_me_options8572.0423.3130.71

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
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

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

SRP 50% 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
The following issues need your attention
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function load_plugin_textdomain() in wp-content/plugins/love-me/love.php:24

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)
There were no browser issues 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
10 plugin tags: love, custom like, custom, heart, custom like button...

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

The main PHP file in "Love Me" ver. 1.1.0 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("love-me.php" instead of "love.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected553 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP213327317
CSS1262107
PO File15514888
JavaScript28041

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.46
Average class complexity69.00
▷ Minimum class complexity69.00
▷ Maximum class complexity69.00
Average method complexity4.40
▷ Minimum method complexity1.00
▷ Maximum method complexity15.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods20
▷ Static methods15.00%
▷ Public methods1995.00%
▷ Protected methods00.00%
▷ Private methods15.00%
Functions0
▷ Named functions00.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 images were found in this plugin