94% smart-recent-comments

Code Review | Smart Recent Comments

WordPress plugin Smart Recent Comments scored 94% from 54 tests.

About plugin

  • Plugin page: smart-recent-comm...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 2.9-3.6
  • WordPress version: 5.8.1
  • First release: Jun 7, 2013
  • Latest release: Aug 19, 2013
  • Number of updates: 3
  • Update frequency: every 24.3 days
  • Top authors: clevelandwebdeveloper (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 713 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

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

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

Analyzing server-side resources used by Smart Recent Comments
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.86 ▲0.1433.41 ▲7.78
Dashboard /wp-admin3.09 ▲0.0343.44 ▼2.17
Posts /wp-admin/edit.php3.14 ▲0.0340.93 ▼4.10
Add New Post /wp-admin/post-new.php5.45 ▲0.0187.78 ▼684.18
Media Library /wp-admin/upload.php3.03 ▲0.0332.43 ▼0.23

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 2 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for Smart Recent Comments
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,703 ▲10715.89 ▲0.2210.83 ▲0.3643.83 ▼3.81
Dashboard /wp-admin2,973 ▲425.92 ▼0.12147.09 ▼0.08113.30 ▼3.11
Posts /wp-admin/edit.php2,739 ▼02.72 ▲0.0168.05 ▲2.5988.08 ▼6.83
Add New Post /wp-admin/post-new.php1,872 ▲37219.11 ▲0.38353.06 ▼38.86108.46 ▲0.59
Media Library /wp-admin/upload.php1,807 ▼35.03 ▲0.00141.09 ▼4.15116.23 ▼8.92

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Uninstall script ran successfully

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
The smoke test was a success, however most plugin functionality was not tested

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× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/smart-recent-comments/index.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
4 plugin tags: smart recent comments, recent comments, wp recent comments, recent comments wordpress

smart-recent-comments/index.php 85% from 13 tests

Analyzing the main PHP file in "Smart Recent Comments" version 1.0
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("smart-recent-comments.php" instead of "index.php")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 680 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin102 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP12915102

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.33
Average class complexity19.00
▷ Minimum class complexity19.00
▷ Maximum class complexity19.00
Average method complexity3.57
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.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