84% runrepeatcom-rating-solution

Code Review | RunRepeat.com Rating Solution

WordPress plugin RunRepeat.com Rating Solution scored84%from 54 tests.

About plugin

  • Plugin page: runrepeatcom-rati...
  • Plugin version: 1.2.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-4.3.1
  • WordPress version: 6.3.1
  • First release: Sep 17, 2015
  • Latest release: Sep 18, 2015
  • Number of updates: 9
  • Update frequency: every 0.1 days
  • Top authors: ovidiu-galatan (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /666 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

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

Server-side resources used by RunRepeat.com Rating Solution
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0242.57 ▲3.69
Dashboard /wp-admin3.33 ▲0.0349.78 ▲2.79
Posts /wp-admin/edit.php3.38 ▲0.0351.20 ▲0.10
Add New Post /wp-admin/post-new.php5.92 ▲0.0389.31 ▼15.56
Media Library /wp-admin/upload.php3.26 ▲0.0337.07 ▲0.39
RunRepeat Solutions /wp-admin/tools.php?page=runrepeatcom-rating-solution/rr_rating_display.php3.2332.12

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

RunRepeat.com Rating Solution: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲6013.30 ▼0.912.01 ▲0.1842.27 ▼2.70
Dashboard /wp-admin2,210 ▲224.85 ▼0.03111.55 ▲2.3242.23 ▲0.11
Posts /wp-admin/edit.php2,090 ▲12.04 ▲0.0435.69 ▼7.1132.86 ▼5.34
Add New Post /wp-admin/post-new.php1,539 ▲1123.18 ▲4.86664.05 ▼17.9054.47 ▼5.43
Media Library /wp-admin/upload.php1,395 ▲74.19 ▼0.01101.17 ▲0.9645.62 ▲0.96
RunRepeat Solutions /wp-admin/tools.php?page=runrepeatcom-rating-solution/rr_rating_display.php8102.0125.8633.90

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Good news, no errors were detected

SRP 50% from 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
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/runrepeatcom-rating-solution/rr_rating_display.php:83

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)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
4 plugin tags: running shoe reviews, reviews, widget, shortcode

runrepeatcom-rating-solution/rr_rating_display.php 92% from 13 tests

This is the main PHP file of "RunRepeat.com Rating Solution" version 1.2.4, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("runrepeatcom-rating-solution.php" instead of "rr_rating_display.php")

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 plugin114 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP117988
JavaScript23526

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity4.00
▷ Minimum class complexity4.00
▷ Maximum class complexity4.00
Average method complexity1.38
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods8
▷ Static methods00.00%
▷ Public methods8100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions150.00%
▷ Anonymous functions150.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
3 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/rr_rating_sc.png0.73KB0.70KB▼ 3.35%
img/screenshot-1.png29.42KB6.54KB▼ 77.75%
img/screenshot-2.png6.92KB3.16KB▼ 54.37%