67% seo-content-randomizer

Code Review | SEO Content Randomizer

WordPress plugin SEO Content Randomizer scored67%from 54 tests.

About plugin

  • Plugin page: seo-content-rando...
  • Plugin version: 3.28.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.0-6.3.0
  • WordPress version: 6.3.1
  • First release: Oct 21, 2018
  • Latest release: Jul 20, 2023
  • Number of updates: 60
  • Update frequency: every 28.9 days
  • Top authors: intellasoftsolutions (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,434 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲5.33MB] [CPU: ▲38.64ms] 75% from 4 tests

A check of server-side resources used by SEO Content Randomizer
It is recommended to improve the following
  • Extra RAM: Extra memory usage must be kept under 5MB (currently 5.33MB on /wp-admin/admin.php?page=freemius)
PageMemory (MB)CPU Time (ms)
Home /8.89 ▲5.4285.77 ▲46.87
Dashboard /wp-admin8.91 ▲5.6093.42 ▲43.62
Posts /wp-admin/edit.php8.91 ▲5.5577.11 ▲25.10
Add New Post /wp-admin/post-new.php10.64 ▲4.75153.37 ▲51.62
Media Library /wp-admin/upload.php8.91 ▲5.6775.67 ▲38.97
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius8.9167.15

Server storage [IO: ▲6.87MB] [DB: ▲0.32MB] Passed 3 tests

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 643 new files
Database: no new tables, 11 new options
New WordPress options
fs_active_plugins
issscr_version
db_upgraded
widget_theysaidso_widget
fs_debug_mode
widget_recent-posts
issscr_original_installation_version
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
...

Browser metrics Passed 4 tests

SEO Content Randomizer: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,863 ▲12813.46 ▼0.921.78 ▼0.2434.35 ▼12.01
Dashboard /wp-admin2,269 ▲1205.06 ▼0.65118.13 ▲13.6445.33 ▲3.94
Posts /wp-admin/edit.php2,152 ▲632.31 ▲0.2939.90 ▼0.2136.89 ▲2.32
Add New Post /wp-admin/post-new.php1,569 ▲5523.09 ▲5.48634.95 ▼57.9828.49 ▼22.46
Media Library /wp-admin/upload.php1,451 ▲604.40 ▲0.1698.86 ▼10.5046.67 ▼0.14
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius1,1261.9127.2926.85

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/seo-content-randomizer/freemius/includes/class-freemius.php+8486
    Undefined property: stdClass::$plugins
  • This plugin does not fully uninstall, leaving 11 options in the database
    • issscr_version
    • widget_recent-posts
    • fs_accounts
    • fs_active_plugins
    • widget_theysaidso_widget
    • issscr_original_installation_version
    • fs_debug_mode
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 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
Almost there! Just fix the following items
  • 2× PHP files output text when accessed directly:
    • > /wp-content/plugins/seo-content-randomizer/public/partials/issscr-public-display.php
    • > /wp-content/plugins/seo-content-randomizer/admin/partials/plugin-issscr-display.php
  • 45× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Taxonomy_Radio' not found in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2/includes/types/CMB2_Type_Taxonomy_Radio_Hierarchical.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Text' not found in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2/includes/types/CMB2_Type_File_Base.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_File_Base' not found in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2/includes/types/CMB2_Type_File_List.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Base' not found in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2/includes/CMB2_Field.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Text' not found in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2/includes/types/CMB2_Type_Oembed.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Cmb2Grid\\trailingslashit() in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2-grid-master/Cmb2GridPluginLoad.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Base' not found in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2/includes/types/CMB2_Type_Multi_Base.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Hookup_Base' not found in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2/includes/rest-api/CMB2_REST.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'Cmb2Grid\\Grid\\Cmb2Grid' not found in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2-grid-master/Grid/Group/Cmb2GroupGrid.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Multi_Base' not found in wp-content/plugins/seo-content-randomizer/admin/plugins/cmb2/includes/types/CMB2_Type_Select.php:13

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 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
7 plugin tags: randomization, randomizing, dynamic content, random, content...

seo-content-randomizer/seo-content-randomizer.php 85% from 13 tests

The entry point to "SEO Content Randomizer" version 3.28.1 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 148 characters long)

Code Analysis 97% from 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
No dangerous file extensions were detected96,812 lines of code in 430 files:
LanguageFilesBlank linesComment linesLines of code
PHP21710,92724,71243,399
PO File12014,31518,50232,323
CSS383431,2997,413
JavaScript191,6071,3386,628
JSON3004,271
Sass17305291,407
Markdown53220984
LESS817970298
SVG20070
XML15419

PHP code 50% from 2 tests

This plugin's cyclomatic complexity and code structure detailed below
It is recommended to fix the following
  • Cyclomatic complexity of classes has to be reduced to less than 1000 (currently 3,073)
Cyclomatic complexity
Average complexity per logical line of code0.57
Average class complexity39.69
▷ Minimum class complexity1.00
▷ Maximum class complexity3,073.00
Average method complexity3.97
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces6
Interfaces0
Traits0
Classes153
▷ Abstract classes127.84%
▷ Concrete classes14192.16%
▷ Final classes00.00%
Methods2,029
▷ Static methods33316.41%
▷ Public methods1,52375.06%
▷ Protected methods1195.86%
▷ Private methods38719.07%
Functions139
▷ Named functions139100.00%
▷ Anonymous functions00.00%
Constants160
▷ Global constants10666.25%
▷ Class constants5433.75%
▷ Public constants54100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
20 PNG files occupy 0.06MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%
admin/plugins/cmb2/images/ui-bg_glass_65_ffffff_1x400.png0.10KB0.10KB▼ 5.71%
admin/plugins/cmb2/images/ico-delete.png0.70KB0.72KB0.00%
admin/plugins/cmb2/images/ui-icons_cd0a0a_256x240.png4.27KB4.11KB▼ 3.78%
admin/plugins/lightgallery/dist/img/vimeo-play.png5.30KB1.56KB▼ 70.65%