84% xmpp-statistics

Code Review | XMPP Statistics

WordPress plugin XMPP Statistics scored 84% from 54 tests.

About plugin

  • Plugin page: xmpp-statistics
  • Plugin version: 1.10
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.1
  • WordPress version: 6.3.1
  • First release: May 8, 2015
  • Latest release: Nov 20, 2022
  • Number of updates: 283
  • Update frequency: every 9.7 days
  • Top authors: Beherit (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 4,536 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.48MB] [CPU: ▼5.81ms] Passed 4 tests

Server-side resources used by XMPP Statistics
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.92 ▲0.4640.29 ▼7.10
Dashboard /wp-admin3.78 ▲0.4745.86 ▼4.32
Posts /wp-admin/edit.php3.89 ▲0.5348.30 ▲4.85
Add New Post /wp-admin/post-new.php6.40 ▲0.5187.48 ▼15.60
Media Library /wp-admin/upload.php3.70 ▲0.4737.41 ▲3.79
XMPP Statistics /wp-admin/options-general.php?page=xmpp-statistics3.6435.37

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

Browser metrics Passed 4 tests

Checking browser requirements for XMPP Statistics
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲7213.19 ▼1.181.87 ▼0.2139.44 ▼6.67
Dashboard /wp-admin2,207 ▲195.80 ▲0.6995.14 ▼13.2843.21 ▼4.08
Posts /wp-admin/edit.php2,093 ▲42.02 ▲0.0139.04 ▼0.4235.67 ▼1.67
Add New Post /wp-admin/post-new.php1,522 ▼1123.42 ▼0.14659.95 ▲58.5550.65 ▼5.20
Media Library /wp-admin/upload.php1,392 ▲44.20 ▼0.0997.60 ▼6.6341.80 ▼5.44
XMPP Statistics /wp-admin/options-general.php?page=xmpp-statistics1,6682.7963.6135.30

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
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=xmpp-statistics
    • > Notice in wp-content/plugins/xmpp-statistics/includes/settings.php+109
    Undefined index: settings-updated

SRP Passed 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration Passed 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
3 plugin tags: jabber, ejabberd, xmpp

xmpp-statistics/xmpp-statistics.php Passed 13 tests

The entry point to "XMPP Statistics" version 1.10 is a PHP file that has certain tags in its header comment area
67 characters long description:
Displays the statistics from ejabberd XMPP server through REST API.

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 detected6,616 lines of code in 25 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript169178254,363
PHP71065502,211
CSS20042

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions94
▷ Named functions94100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.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 are no PNG files in this plugin