84% acymailing-custom-headers

Code Review | Custom headers - AcyMailing

WordPress plugin Custom headers - AcyMailing scored84%from 54 tests.

About plugin

  • Plugin page: acymailing-custom...
  • Plugin version: 2.1
  • PHP compatiblity: 7.2.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.3.2
  • WordPress version: 6.3.1
  • First release: May 24, 2021
  • Latest release: Oct 24, 2023
  • Number of updates: 15
  • Update frequency: every 59.0 days
  • Top authors: acyba (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,212 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
This plugin's installer ran successfully

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

Analyzing server-side resources used by Custom headers - AcyMailing
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0134.04 ▼3.16
Dashboard /wp-admin3.32 ▲0.0143.72 ▼3.76
Posts /wp-admin/edit.php3.37 ▲0.0143.81 ▼0.10
Add New Post /wp-admin/post-new.php5.90 ▲0.0183.05 ▼5.03
Media Library /wp-admin/upload.php3.24 ▲0.0135.13 ▲2.19

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Custom headers - AcyMailing
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.34 ▼0.051.51 ▼0.2041.82 ▲1.23
Dashboard /wp-admin2,195 ▲205.64 ▼0.0880.33 ▼17.0138.16 ▼8.22
Posts /wp-admin/edit.php2,100 ▼02.03 ▲0.0334.42 ▼2.4433.92 ▼0.03
Add New Post /wp-admin/post-new.php1,531 ▲322.96 ▼0.34663.83 ▼27.5853.44 ▼7.91
Media Library /wp-admin/upload.php1,400 ▼34.26 ▲0.0898.73 ▼5.1941.72 ▼7.59

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'AcyMailing\\Libraries\\acymPlugin' not found in wp-content/plugins/acymailing-custom-headers/plugin.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_deactivation_hook() in wp-content/plugins/acymailing-custom-headers/acymailing-customheaders.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 96% 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
3 plugin tags: newsletter, headers, acymailing

acymailing-custom-headers/acymailing-customheaders.php 92% from 13 tests

The primary PHP file in "Custom headers - AcyMailing" version 2.1 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("acymailing-custom-headers.php" instead of "acymailing-customheaders.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
Good job! No executable or dangerous file extensions detected62 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP213862

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.46
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity3.50
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.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.01MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
banner.png14.78KB5.10KB▼ 65.51%