73% wpadmin-backup-to-aws4

Code Review | WPAdmin Backup to AWS4

WordPress plugin WPAdmin Backup to AWS4 scored 73% from 54 tests.

About plugin

  • Plugin page: wpadmin-backup-to...
  • Plugin version: 0.7.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4.2-4.9.7
  • WordPress version: 6.3.1
  • First release: Jan 17, 2017
  • Latest release: Jul 7, 2018
  • Number of updates: 22
  • Update frequency: every 24.2 days
  • Top authors: luckychingi (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,066 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▼1.96MB] [CPU: ▼53.83ms] Passed 4 tests

An overview of server-side resources used by WPAdmin Backup to AWS4
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.434.49 ▼36.40
Dashboard /wp-admin2.05 ▼1.265.79 ▼41.55
Posts /wp-admin/edit.php2.05 ▼1.315.55 ▼41.49
Add New Post /wp-admin/post-new.php2.05 ▼3.845.09 ▼95.89
Media Library /wp-admin/upload.php2.05 ▼1.184.92 ▼31.34

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

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

Browser metrics Passed 4 tests

WPAdmin Backup to AWS4: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,828 ▲9313.67 ▼0.731.67 ▼0.3142.82 ▼10.26
Dashboard /wp-admin2,220 ▲295.84 ▲0.9498.60 ▼2.6040.33 ▼3.48
Posts /wp-admin/edit.php2,106 ▲172.00 ▲0.0040.08 ▲2.9540.51 ▲6.06
Add New Post /wp-admin/post-new.php1,545 ▲122.79 ▲4.40654.03 ▲38.1161.44 ▲9.49
Media Library /wp-admin/upload.php1,408 ▲204.23 ▼0.0493.92 ▼3.9741.74 ▼7.35

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • Uninstall procedure validation failed for this plugin
    • > User notice in wp-includes/functions.php+5905
    Function wp_register_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the fontawesome handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options

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
The smoke test was a success, however most plugin functionality was not tested

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
Almost there! Just fix the following items
  • 100× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'GuzzleHttp\\Exception\\RequestException' not found in wp-content/plugins/wpadmin-backup-to-aws4/admin/GuzzleHttp/Exception/TooManyRedirectsException.php:4
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/wpadmin-backup-to-aws4/admin/GuzzleHttp/Promise/RejectedPromise.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'GuzzleHttp\\Promise\\RejectionException' not found in wp-content/plugins/wpadmin-backup-to-aws4/admin/GuzzleHttp/Promise/AggregateException.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Aws\\Api\\Shape' not found in wp-content/plugins/wpadmin-backup-to-aws4/admin/Aws/Api/StructureShape.php:7
    • > PHP Fatal error
      Uncaught Error: Interface 'Aws\\HashInterface' not found in wp-content/plugins/wpadmin-backup-to-aws4/admin/Aws/PhpHash.php:7
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/wpadmin-backup-to-aws4/admin/GuzzleHttp/Psr7/DroppingStream.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Aws\\Api\\AbstractModel' not found in wp-content/plugins/wpadmin-backup-to-aws4/admin/Aws/Api/Service.php:11
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Cookie\\CookieJarInterface' not found in wp-content/plugins/wpadmin-backup-to-aws4/admin/GuzzleHttp/Cookie/CookieJar.php:10
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/wpadmin-backup-to-aws4/admin/GuzzleHttp/Psr7/BufferStream.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/wpadmin-backup-to-aws4/admin/wpa-awss4-admin.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need to be fixed:
  • Plugin Name: You should set the name of your plugin on the first line ( === wpadmin-backup-to-aws4 === )
  • Requires php: The plugin version is formatted incorrectly
Please take inspiration from this readme.txt

wpadmin-backup-to-aws4/wpadmin-backup-to-aws4.php 92% from 13 tests

The primary PHP file in "WPAdmin Backup to AWS4" version 0.7.1 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 208 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected20,742 lines of code in 434 files:
LanguageFilesBlank linesComment linesLines of code
PHP4323,8809,78020,739
JavaScript1052
CSS1041

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity11.07
▷ Minimum class complexity1.00
▷ Maximum class complexity74.00
Average method complexity2.40
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
Namespaces24
Interfaces24
Traits9
Classes183
▷ Abstract classes42.19%
▷ Concrete classes17997.81%
▷ Final classes84.47%
Methods1,552
▷ Static methods17611.34%
▷ Public methods1,08569.91%
▷ Protected methods523.35%
▷ Private methods41526.74%
Functions335
▷ Named functions7020.90%
▷ Anonymous functions26579.10%
Constants117
▷ Global constants75.98%
▷ Class constants11094.02%
▷ Public constants110100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/asset/images/folder.png1.33KB0.70KB▼ 47.50%
admin/asset/images/delete.png2.97KB1.12KB▼ 62.32%