84% ajax-message

Code Review | Ajax Message

WordPress plugin Ajax Message scored84%from 54 tests.

About plugin

  • Plugin page: ajax-message
  • Plugin version: 1.0
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-5.6
  • WordPress version: 6.3.1
  • First release: Sep 25, 2017
  • Latest release: Feb 21, 2021
  • Number of updates: 7
  • Update frequency: every 178.0 days
  • Top authors: keksus (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /845 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.09MB] [CPU: ▼11.35ms] Passed 4 tests

Server-side resources used by Ajax Message
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0322.37 ▼21.42
Dashboard /wp-admin3.42 ▲0.1145.47 ▼3.57
Posts /wp-admin/edit.php3.53 ▲0.1745.74 ▼4.95
Add New Post /wp-admin/post-new.php6.00 ▲0.1179.58 ▼15.45
Media Library /wp-admin/upload.php3.34 ▲0.1135.67 ▲3.54
Ajax Message /wp-admin/options-general.php?page=ae_options_group3.1525.86

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 16 new files
Database: no new tables, 8 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
ajax-message
widget_ae
widget_recent-posts
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Ajax Message
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,928 ▲15713.59 ▼0.775.42 ▲3.3436.94 ▼5.68
Dashboard /wp-admin2,210 ▲225.85 ▲0.03103.15 ▼14.7540.13 ▼3.14
Posts /wp-admin/edit.php2,090 ▼22.02 ▼0.0338.51 ▼0.5535.62 ▲1.67
Add New Post /wp-admin/post-new.php1,531 ▼417.88 ▼5.26675.92 ▲73.6658.68 ▲7.40
Media Library /wp-admin/upload.php1,392 ▲44.19 ▼0.0193.65 ▲0.8647.79 ▲5.26
Ajax Message /wp-admin/options-general.php?page=ae_options_group1,0722.0823.5933.74

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
The following items require your attention
  • The uninstall procedure has failed, leaving 7 options in the database
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • widget_ae
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/options-general.php?page=ae_options_group
    • > Warning in wp-content/plugins/ajax-message/ajax-message.php+93
    Use of undefined constant jquery - assumed 'jquery' (this will throw an Error in a future version of PHP)

SRP Passed 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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: contact, form, feedback, contact form, ajax

ajax-message/ajax-message.php 92% from 13 tests

Analyzing the main PHP file in "Ajax Message" version 1.0
Please take the time to fix the following:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin3,295 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
SVG1032,227
CSS41558506
PHP17031457
JavaScript276105

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity9.00
▷ Minimum class complexity9.00
▷ Maximum class complexity9.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions21
▷ Named functions21100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin