73% wpvivid-backup-mainwp

Code Review | WPvivid Backup for MainWP

WordPress plugin WPvivid Backup for MainWP scored73%from 54 tests.

About plugin

  • Plugin page: wpvivid-backup-ma...
  • Plugin version: 0.9.32
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.4.1
  • WordPress version: 6.3.1
  • First release: Oct 8, 2019
  • Latest release: Nov 13, 2023
  • Number of updates: 70
  • Update frequency: every 21.4 days
  • Top authors: wpvivid (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

7,000+ active /141,237 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▲5.38MB] [CPU: ▲18.44ms] 75% from 4 tests

A check of server-side resources used by WPvivid Backup for MainWP
Please fix the following
  • Extra RAM: Extra memory usage must be kept under 5MB (currently 5.38MB on /wp-admin/upload.php)
PageMemory (MB)CPU Time (ms)
Home /8.88 ▲5.4184.23 ▲42.25
Dashboard /wp-admin8.71 ▲5.3675.33 ▲14.29
Posts /wp-admin/edit.php8.76 ▲5.4081.55 ▲23.27
Add New Post /wp-admin/post-new.php11.23 ▲5.34117.59 ▲5.80
Media Library /wp-admin/upload.php8.64 ▲5.4066.58 ▲30.40

Server storage [IO: ▲6.73MB] [DB: ▲0.01MB] Passed 3 tests

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 829 new files
Database: 4 new tables, 7 new options
New tables
wp_mainwp_wpvivid_global_options
wp_mainwp_wpvividmeta
wp_mainwp_wpvivid
wp_mainwp_wpvivid_global
New WordPress options
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
db_upgraded
mainwp_wpvivid_backups_db_version
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for WPvivid Backup for MainWP
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,820 ▲7314.28 ▼0.431.73 ▼0.4441.55 ▼0.17
Dashboard /wp-admin2,228 ▲504.87 ▼0.8599.96 ▼14.1942.24 ▼3.81
Posts /wp-admin/edit.php2,107 ▲72.29 ▲0.2942.93 ▼0.3435.91 ▲2.11
Add New Post /wp-admin/post-new.php1,546 ▲1123.11 ▲4.49605.96 ▼60.3452.05 ▼19.71
Media Library /wp-admin/upload.php1,428 ▲254.29 ▲0.08102.12 ▲0.9540.93 ▼6.09

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • The plugin did not uninstall successfully, leaving 4 tables in the database
    • wp_mainwp_wpvivid_global
    • wp_mainwp_wpvividmeta
    • wp_mainwp_wpvivid_global_options
    • wp_mainwp_wpvivid
  • This plugin does not fully uninstall, leaving 7 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • mainwp_wpvivid_backups_db_version
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

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

SRP 50% 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
Please fix the following items
  • 477× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\Handler\\AbstractHandler' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/monolog/monolog/src/Monolog/Handler/FilterHandler.php:24
    • > PHP Fatal error
      Uncaught Error: Class 'Guzzle\\Common\\Version' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/guzzle/guzzle/src/Guzzle/Plugin/Cache/DefaultCacheKeyProvider.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\TestCase' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/monolog/monolog/tests/Monolog/Handler/MailHandlerTest.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\TestCase' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/monolog/monolog/tests/Monolog/Handler/PHPConsoleHandlerTest.php:28
    • > PHP Fatal error
      Uncaught Error: Interface 'Guzzle\\Service\\Command\\ResponseParserInterface' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/guzzle/guzzle/src/Guzzle/Service/Command/DefaultResponseParser.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\Processor\\MemoryProcessor' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/monolog/monolog/src/Monolog/Processor/MemoryPeakUsageProcessor.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'Guzzle\\Plugin\\Backoff\\AbstractBackoffStrategy' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/guzzle/guzzle/src/Guzzle/Plugin/Backoff/ConstantBackoffStrategy.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'Guzzle\\Common\\AbstractHasDispatcher' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/guzzle/guzzle/src/Guzzle/Http/Client.php:24
    • > PHP Fatal error
      Uncaught Error: Interface 'Symfony\\Component\\EventDispatcher\\Debug\\TraceableEventDispatcherInterface' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/symfony/event-dispatcher/Debug/TraceableEventDispatcher.php:27
    • > PHP Fatal error
      Uncaught Error: Interface 'Monolog\\Processor\\ProcessorInterface' not found in wp-content/plugins/wpvivid-backup-mainwp/vendor/monolog/monolog/src/Monolog/Processor/MemoryProcessor.php:19

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that need to be fixed: You can look at the official readme.txt

wpvivid-backup-mainwp/wpvivid-backup-mainwp.php 92% from 13 tests

The primary PHP file in "WPvivid Backup for MainWP" version 0.9.32 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 231 characters long)

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
No dangerous file extensions were detected116,581 lines of code in 759 files:
LanguageFilesBlank linesComment linesLines of code
PHP67115,78838,01198,803
JavaScript32102,2946,873
Markdown331,64105,660
CSS594532,927
JSON38802,119
XML5140125
YAML312065
make1409

PHP code 50% from 2 tests

This is a very shot review of cyclomatic complexity and code structure
Please fix the following
  • Method cyclomatic complexity has to be reduced to less than 100 (currently 154)
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity17.33
▷ Minimum class complexity1.00
▷ Maximum class complexity651.00
Average method complexity3.07
▷ Minimum method complexity1.00
▷ Maximum method complexity154.00
Code structure
Namespaces77
Interfaces79
Traits5
Classes606
▷ Abstract classes233.80%
▷ Concrete classes58396.20%
▷ Final classes122.06%
Methods5,768
▷ Static methods2774.80%
▷ Public methods5,14489.18%
▷ Protected methods3656.33%
▷ Private methods2594.49%
Functions294
▷ Named functions6722.79%
▷ Anonymous functions22777.21%
Constants494
▷ Global constants26754.05%
▷ Class constants22745.95%
▷ Public constants227100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
41 PNG files occupy 0.12MB with 0.04MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/images/backup-migration.png2.14KB1.37KB▼ 36.03%
admin/images/pro.png2.23KB1.18KB▼ 47.12%
admin/js/jstree/dist/themes/default/32px.png5.53KB2.93KB▼ 47.10%
admin/images/storage-wasabi(gray).png2.68KB1.43KB▼ 46.43%
admin/js/jstree/dist/themes/default-dark/32px.png1.49KB1.53KB0.00%