84% right-here-right-now

Code Review | Right Here Right Now

WordPress plugin Right Here Right Now scored84%from 54 tests.

About plugin

  • Plugin page: right-here-right-now
  • Plugin version: 1.1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.2
  • WordPress version: 6.3.1
  • First release: May 22, 2013
  • Latest release: May 19, 2019
  • Number of updates: 13
  • Update frequency: every 168.3 days
  • Top authors: m_uysl (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

10+ active /1,522 total downloads

Benchmarks

Plugin footprint 83% 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.01MB] [CPU: ▼5.46ms] Passed 4 tests

Server-side resources used by Right Here Right Now
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0133.39 ▼10.28
Dashboard /wp-admin3.31 ▲0.0147.36 ▲1.96
Posts /wp-admin/edit.php3.36 ▲0.0145.67 ▼2.71
Add New Post /wp-admin/post-new.php5.91 ▲0.0388.57 ▼7.84
Media Library /wp-admin/upload.php3.24 ▲0.0134.15 ▼1.00

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Right Here Right Now
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,841 ▲10613.24 ▼1.111.88 ▼0.3637.20 ▼5.80
Dashboard /wp-admin2,241 ▲505.89 ▼0.01113.05 ▲12.8440.13 ▼6.46
Posts /wp-admin/edit.php2,098 ▲92.03 ▼0.0235.27 ▼5.7832.48 ▼2.32
Add New Post /wp-admin/post-new.php1,537 ▲323.06 ▲0.01628.89 ▲33.7566.56 ▲18.29
Media Library /wp-admin/upload.php1,400 ▲154.30 ▲0.0995.76 ▼2.0741.11 ▼1.06

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting 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 | 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
  • 3× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Warning
      require_once(/includes/functions.php): failed to open stream: No such file or directory in wp-content/plugins/right-here-right-now/tests/bootstrap.php on line 2
    • > PHP Fatal error
      require_once(): Failed opening required '/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/right-here-right-now/tests/bootstrap.php on line 2
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/right-here-right-now/tests/test-utils.php:3

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 on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Screenshots: Please add an image for screenshot #1 (screenshot-1.png)
You can take inspiration from this readme.txt

right-here-right-now/right-here-right-now.php Passed 13 tests

The principal PHP file in "Right Here Right Now" v. 1.1.2 is loaded by WordPress automatically on each request
68 characters long description:
Replace wordpress right now widget with right-here-right-now plugin.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected1,296 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript21851471,123
PHP34333111
YAML27334
Markdown18014
XML10014

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.12
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods1
▷ Static methods00.00%
▷ Public methods1100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions7
▷ Named functions7100.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
1 PNG file occupies 0.13MB with 0.12MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png135.77KB14.46KB▼ 89.35%