78% companion-auto-update

Code Review | Companion Auto Update

WordPress plugin Companion Auto Update scored78%from 54 tests.

About plugin

  • Plugin page: companion-auto-up...
  • Plugin version: 3.8.7.1
  • PHP compatiblity: 5.1+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6.0-6.2
  • WordPress version: 6.3.1
  • First release: May 23, 2016
  • Latest release: Mar 31, 2023
  • Number of updates: 215
  • Update frequency: every 11.6 days
  • Top authors: Papin (100%)

Code review

54 tests

User reviews

102 reviews

Install metrics

70,000+ active /3,599,567 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.33MB] [CPU: ▲0.50ms] Passed 4 tests

An overview of server-side resources used by Companion Auto Update
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.79 ▲0.3350.05 ▲4.02
Dashboard /wp-admin3.67 ▲0.3759.12 ▲10.64
Posts /wp-admin/edit.php3.74 ▲0.3856.68 ▲3.86
Add New Post /wp-admin/post-new.php6.21 ▲0.3289.88 ▼11.47
Media Library /wp-admin/upload.php3.55 ▲0.3241.66 ▲5.57
Auto Updater /wp-admin/tools.php?page=cau-settings3.7946.12

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 23 new files
Database: 2 new tables, 7 new options
New tables
wp_update_log
wp_auto_updates
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
cau_db_version
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

Companion Auto Update: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,919 ▲13314.37 ▼0.251.93 ▲0.2242.02 ▼2.04
Dashboard /wp-admin2,300 ▲1265.67 ▲0.1190.67 ▲2.6241.33 ▼6.99
Posts /wp-admin/edit.php2,098 ▼22.01 ▲0.0338.97 ▲0.3537.47 ▼9.47
Add New Post /wp-admin/post-new.php1,525 ▼1123.28 ▲4.88675.87 ▲44.6354.67 ▼9.37
Media Library /wp-admin/upload.php1,400 ▼04.20 ▼0.0799.22 ▼14.8043.62 ▲0.01
Auto Updater /wp-admin/tools.php?page=cau-settings1,7822.3028.7952.77

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • The uninstall procedure has failed, leaving 7 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • cau_db_version
    • db_upgraded
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
The following issues need your attention
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/companion-auto-update/companion-auto-update.php
  • 5× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function cau_url() in wp-content/plugins/companion-auto-update/admin/log.php:28
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/companion-auto-update/cau_functions.php:1128
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/companion-auto-update/admin/pluginlist.php:55
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_next_scheduled() in wp-content/plugins/companion-auto-update/admin/dashboard.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/companion-auto-update/admin/status.php:7

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration 97% 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
Please fix the following attributes:
  • Tags: Please reduce the number of tags, currently 32 tag instead of maximum 10
The official readme.txt might help

companion-auto-update/companion-auto-update.php Passed 13 tests

The primary PHP file in "Companion Auto Update" version 3.8.7.1 is used by WordPress to initiate all plugin functionality
72 characters long description:
This plugin auto updates all plugins, all themes and the wordpress core.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected2,956 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
PHP108341,2821,520
SVG966889
CSS22125547

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity13.00
▷ Minimum class complexity13.00
▷ Maximum class complexity13.00
Average method complexity7.00
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions86
▷ Named functions86100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
No PNG files were detected