84% get-liveinternet-statistics

Code Review | Статистика сайта по счетчику LiveInternet.ru

WordPress plugin Статистика сайта по счетчику LiveInternet.ru scored84%from 54 tests.

About plugin

  • Plugin page: get-liveinternet-...
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-3.5.1
  • WordPress version: 6.3.1
  • First release: May 12, 2013
  • Latest release: May 12, 2013
  • Number of updates: 2
  • Update frequency: every 1.0 days
  • Top authors: fcobra (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /4,369 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.01MB] [CPU: ▼7.32ms] Passed 4 tests

This is a short check of server-side resources used by Статистика сайта по счетчику LiveInternet.ru
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.76 ▼3.27
Dashboard /wp-admin3.28 ▼0.07192.04 ▲127.74
Posts /wp-admin/edit.php3.38 ▲0.0246.51 ▼4.09
Add New Post /wp-admin/post-new.php5.91 ▲0.0282.68 ▼19.17
Media Library /wp-admin/upload.php3.25 ▲0.0233.54 ▼2.74

Server storage [IO: ▲0.01MB] [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: 2 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Статистика сайта по счетчику LiveInternet.ru
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,833 ▲8713.27 ▼1.041.62 ▼0.1438.95 ▼3.02
Dashboard /wp-admin2,236 ▲485.85 ▼0.0597.68 ▼13.9039.25 ▼1.12
Posts /wp-admin/edit.php2,089 ▼02.01 ▼0.0334.46 ▼9.0933.42 ▼1.02
Add New Post /wp-admin/post-new.php1,533 ▲1423.06 ▼0.15605.04 ▼44.5649.66 ▼2.76
Media Library /wp-admin/upload.php1,391 ▲34.20 ▼0.0695.57 ▼16.5240.13 ▼8.33

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
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • 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
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/get-liveinternet-statistics/getlicounterparams.php:160

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === get-liveinternet-statistics === )
You can look at the official readme.txt

get-liveinternet-statistics/getlicounterparams.php 92% from 13 tests

"Статистика сайта по счетчику LiveInternet.ru" version 0.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("get-liveinternet-statistics.php" instead of "getlicounterparams.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected100 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP13228100

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity16.00
▷ Minimum class complexity16.00
▷ Maximum class complexity16.00
Average method complexity4.00
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods5100.00%
▷ Public methods120.00%
▷ Protected methods480.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

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin