66% ssl-atlas-free-ssl-certificate-https-redirect

Code Review | SSL Atlas - Free SSL Certificate & HTTPS Redirect for WordPress

WordPress plugin SSL Atlas - Free SSL Certificate & HTTPS Redirect for WordPress scored 66% from 54 tests.

About plugin

  • Plugin page: ssl-atlas-free-ss...
  • Plugin version: 1.1.1
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2-6.0
  • WordPress version: 6.3.1
  • First release: Oct 12, 2021
  • Latest release: Jun 1, 2022
  • Number of updates: 9
  • Update frequency: every 25.8 days
  • Top authors: sslatlas (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 777 total downloads

Benchmarks

Plugin footprint 82% 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: ▲5.22MB] [CPU: ▲23.47ms] 75% from 4 tests

Server-side resources used by SSL Atlas - Free SSL Certificate & HTTPS Redirect for WordPress
Please fix the following
  • Extra RAM: The extra memory usage must be under 5MB (currently 5.22MB on /wp-admin/admin.php?page=ssl-atlas)
PageMemory (MB)CPU Time (ms)
Home /8.75 ▲5.2970.17 ▲30.41
Dashboard /wp-admin8.77 ▲5.4675.47 ▲22.22
Posts /wp-admin/edit.php8.77 ▲5.4183.30 ▲33.71
Add New Post /wp-admin/post-new.php10.60 ▲4.71111.84 ▲7.52
Media Library /wp-admin/upload.php8.77 ▲5.5473.71 ▲38.94
Freemius Debug [v.2.4.3] /wp-admin/admin.php?page=freemius8.7767.29
SSL Atlas - Free SSL Certificate & HTTPS Redirect /wp-admin/admin.php?page=ssl-atlas8.7765.43

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 550 new files
Database: no new tables, 10 new options
New WordPress options
fs_debug_mode
fs_accounts
widget_recent-comments
db_upgraded
widget_recent-posts
fs_active_plugins
can_compress_scripts
fs_gdpr
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for SSL Atlas - Free SSL Certificate & HTTPS Redirect for WordPress
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,842 ▲10713.28 ▼1.484.75 ▲3.1827.43 ▼14.78
Dashboard /wp-admin2,248 ▲605.81 ▼0.08110.77 ▲11.4544.83 ▲5.33
Posts /wp-admin/edit.php2,131 ▲422.04 ▼0.0135.11 ▼4.5534.64 ▼2.45
Add New Post /wp-admin/post-new.php1,540 ▲722.92 ▼0.32632.48 ▼19.6256.52 ▼6.48
Media Library /wp-admin/upload.php1,427 ▲364.26 ▲0.0396.15 ▼16.3443.59 ▼4.15
Freemius Debug [v.2.4.3] /wp-admin/admin.php?page=freemius1,0871.8929.9132.23
SSL Atlas - Free SSL Certificate & HTTPS Redirect /wp-admin/admin.php?page=ssl-atlas1,0041.7627.9852.10

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
  • The uninstall procedure has failed, leaving 11 options in the database
    • widget_recent-comments
    • ssl_atlas_deactivated
    • db_upgraded
    • widget_theysaidso_widget
    • fs_accounts
    • can_compress_scripts
    • fs_active_plugins
    • theysaidso_admin_options
    • fs_debug_mode
    • widget_recent-posts
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

SRP 0% 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
Almost there! Just fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/ssl_atlas.php
  • 76× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\UriInterface' not found in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/vendor/guzzlehttp/psr7/src/Uri.php:14
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/vendor/guzzlehttp/psr7/src/PumpStream.php:17
    • > PHP Fatal error
      Uncaught Error: Interface 'LayerShifter\\TLDExtract\\ResultInterface' not found in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/vendor/layershifter/tld-extract/src/Result.php:27
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_deactivation_hook() in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/ssl_atlas/classes/class.ssl_atlas_admin.php:47
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/vendor/guzzlehttp/promises/src/RejectedPromise.php:11
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Cookie\\CookieJarInterface' not found in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/vendor/guzzlehttp/guzzle/src/Cookie/CookieJar.php:10
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/vendor/guzzlehttp/psr7/src/LimitStream.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/vendor/layershifter/tld-support/tests/Helpers/StrTest.php:18
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/ssl_atlas/classes/class.ssl_atlas_cloudflare_fix.php:49
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/vendor/guzzlehttp/promises/src/FulfilledPromise.php:11

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 83% from 29 tests

readme.txt 94% from 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
These attributes need to be fixed: You can take inspiration from this readme.txt

ssl-atlas-free-ssl-certificate-https-redirect/ssl_atlas.php 69% from 13 tests

The primary PHP file in "SSL Atlas - Free SSL Certificate & HTTPS Redirect for WordPress" version 1.1.1 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Domain Path: The domain path should use only dashes and lowercase characters ("ssl_atlas/languages")
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Description: Keep the plugin description shorter than 140 characters (currently 146 characters long)
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("ssl-atlas-free-ssl-certificate-https-redirect.php" instead of "ssl_atlas.php")

Code Analysis 0% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Almost there! Just fix the following issues
  • You should never include executable (binary) or otherwise dangerous files in your plugin
    • .crt - Security Certificate in Firefox, IE, Chrome, Safari
      • wp-content/plugins/ssl-atlas-free-ssl-certificate-https-redirect/ssl_atlas/keys/cabundle.crt
90,994 lines of code in 442 files:
LanguageFilesBlank linesComment linesLines of code
PHP30611,20826,39178,990
Markdown171,20303,745
SVG68002,820
CSS174031402,111
JavaScript103263621,908
JSON15001,294
XML31057
YAML415050
Dockerfile18010
make1409

PHP code 0% from 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Please fix the following
  • Please reduce cyclomatic complexity of classes to less than 1000 (currently 2,910)
  • Method cyclomatic complexity has to be reduced to less than 100 (currently 179)
Cyclomatic complexity
Average complexity per logical line of code0.56
Average class complexity34.65
▷ Minimum class complexity1.00
▷ Maximum class complexity2,910.00
Average method complexity4.22
▷ Minimum method complexity1.00
▷ Maximum method complexity179.00
Code structure
Namespaces27
Interfaces17
Traits2
Classes188
▷ Abstract classes52.66%
▷ Concrete classes18397.34%
▷ Final classes3116.94%
Methods2,268
▷ Static methods50222.13%
▷ Public methods1,73476.46%
▷ Protected methods200.88%
▷ Private methods51422.66%
Functions312
▷ Named functions20666.03%
▷ Anonymous functions10633.97%
Constants321
▷ Global constants15046.73%
▷ Class constants17153.27%
▷ Public constants171100.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
14 PNG files occupy 0.24MB with 0.14MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
vendor/layershifter/tld-database/logo.png11.31KB4.89KB▼ 56.78%
ssl_atlas/img/header-logo.png7.05KB3.38KB▼ 52.13%
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
ssl_atlas/img/plugin-mascot.png48.86KB13.42KB▼ 72.54%
ssl_atlas/img/pricing-badge.png11.20KB5.02KB▼ 55.23%