84% wp-advanced-newsletter

Code Review | WP Advanced newsletter

WordPress plugin WP Advanced newsletter scored 84% from 54 tests.

About plugin

  • Plugin page: wp-advanced-newsl...
  • Plugin version: 1.0.5
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.6
  • WordPress version: 6.3.1
  • First release: Mar 31, 2016
  • Latest release: Jun 29, 2021
  • Number of updates: 25
  • Update frequency: every 76.6 days
  • Top authors: cedcommerce (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,900 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.55MB] [CPU: ▼3.57ms] Passed 4 tests

Server-side resources used by WP Advanced newsletter
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.94 ▲0.4833.46 ▼4.27
Dashboard /wp-admin3.87 ▲0.5749.47 ▲3.99
Posts /wp-admin/edit.php3.92 ▲0.5753.34 ▲1.76
Add New Post /wp-admin/post-new.php6.47 ▲0.5987.98 ▼15.77
Media Library /wp-admin/upload.php3.80 ▲0.5739.67 ▲5.82

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 118 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for WP Advanced newsletter
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,058 ▲30114.73 ▲0.1720.81 ▲18.8543.39 ▼4.52
Dashboard /wp-admin2,282 ▲945.17 ▼0.73109.58 ▲7.0738.00 ▼5.57
Posts /wp-admin/edit.php2,168 ▲792.45 ▲0.4243.50 ▲0.8434.33 ▼0.47
Add New Post /wp-admin/post-new.php1,564 ▲3023.67 ▲0.69665.19 ▲40.6035.88 ▼15.87
Media Library /wp-admin/upload.php1,464 ▲794.47 ▲0.1299.84 ▼0.3741.56 ▼3.83

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
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

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
Good news, no errors were detected

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
Almost there! Just fix the following items
  • 56× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/wp-advanced-newsletter/email-service/activecampaign/includes/Auth.class.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/wp-advanced-newsletter/email-service/activecampaign/includes/Campaign.class.php:3
    • > PHP Fatal error
      Uncaught Error: Interface 'Ctct\\Auth\\CtctDataStore' not found in wp-content/plugins/wp-advanced-newsletter/email-service/constant_contact_api/src/Ctct/Auth/SessionDataStore.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Ctct\\Components\\Component' not found in wp-content/plugins/wp-advanced-newsletter/email-service/constant_contact_api/src/Ctct/Components/Tracking/ClickActivity.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/wp-advanced-newsletter/email-service/activecampaign/includes/Form.class.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'Ctct\\Services\\BaseService' not found in wp-content/plugins/wp-advanced-newsletter/email-service/constant_contact_api/src/Ctct/Services/ContactTrackingService.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/wp-advanced-newsletter/email-service/activecampaign/includes/Message.class.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'Ctct\\Services\\BaseService' not found in wp-content/plugins/wp-advanced-newsletter/email-service/constant_contact_api/src/Ctct/Services/ContactService.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'Ctct\\Services\\BaseService' not found in wp-content/plugins/wp-advanced-newsletter/email-service/constant_contact_api/src/Ctct/Services/CampaignScheduleService.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/wp-advanced-newsletter/email-service/activecampaign/includes/List.class.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: email newsletter, popup newsletter, email marketing, newsletter subscription, wordpress newsletter...

wp-advanced-newsletter/wp-advanced-newsletter.php 85% from 13 tests

The primary PHP file in "WP Advanced newsletter" version 1.0.5 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 178 characters long)
  • Domain Path: The domain path folder was not found ("/language/")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected22,589 lines of code in 105 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript52,6561,74213,934
PHP891,3094,8108,024
CSS53018377
PO File189139194
XML30043
YAML15015
INI1002

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.16
Average class complexity5.83
▷ Minimum class complexity1.00
▷ Maximum class complexity55.00
Average method complexity1.70
▷ Minimum method complexity1.00
▷ Maximum method complexity44.00
Code structure
Namespaces13
Interfaces2
Traits0
Classes75
▷ Abstract classes22.67%
▷ Concrete classes7397.33%
▷ Final classes00.00%
Methods541
▷ Static methods336.10%
▷ Public methods53598.89%
▷ Protected methods20.37%
▷ Private methods40.74%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants23
▷ Global constants23100.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
5 PNG files occupy 0.04MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
colorbox/images/controls.png0.49KB0.57KB0.00%
colorbox/images/overlay.png0.11KB0.15KB0.00%
assets/images/logo.png33.43KB16.71KB▼ 50.03%
assets/images/mail.png1.92KB1.86KB▼ 3.30%
assets/images/help.png2.50KB1.80KB▼ 27.93%