84% amigo-extensions

Code Review | Amigo Extensions

WordPress plugin Amigo Extensions scored84%from 54 tests.

About plugin

  • Plugin page: amigo-extensions
  • Plugin version: 1.0.16
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.1
  • WordPress version: 6.3.1
  • First release: Apr 27, 2021
  • Latest release: Nov 15, 2022
  • Number of updates: 16
  • Update frequency: every 35.8 days
  • Top authors: amigothemes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /3,829 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼0.68ms] Passed 4 tests

Server-side resources used by Amigo Extensions
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0241.14 ▲0.27
Dashboard /wp-admin3.32 ▲0.0244.87 ▼6.63
Posts /wp-admin/edit.php3.37 ▲0.0248.27 ▼0.00
Add New Post /wp-admin/post-new.php5.90 ▲0.02133.52 ▲43.87
Media Library /wp-admin/upload.php3.24 ▲0.0135.68 ▲3.65

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 104 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Amigo Extensions
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6514.48 ▲0.091.80 ▼0.0642.24 ▲0.82
Dashboard /wp-admin2,209 ▲215.90 ▲0.99100.30 ▼8.2839.21 ▼4.71
Posts /wp-admin/edit.php2,086 ▼32.04 ▲0.0340.25 ▲2.7437.45 ▲3.77
Add New Post /wp-admin/post-new.php1,519 ▲523.17 ▲5.72678.65 ▼5.1664.52 ▲1.07
Media Library /wp-admin/upload.php1,388 ▼04.17 ▼0.0295.53 ▼12.8242.33 ▼1.43

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% 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
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% 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
Please take a closer look at the following
  • 32× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/amigo-extensions/includes/industri/template-parts/sections/section-c2a.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/amigo-extensions/includes/industri/defaults/default-widgets.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/amigo-extensions/includes/aqwa/customizer/blog-customizer.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/amigo-extensions/includes/industri/customizer/customizer-footer.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/amigo-extensions/includes/industri/template-parts/sections/section-info.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function update_option() in wp-content/plugins/amigo-extensions/includes/aqwa/defaults/default-widgets.php:21
    • > PHP Warning
      Use of undefined constant AMIGO_PLUGIN_DIR_PATH - assumed 'AMIGO_PLUGIN_DIR_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/amigo-extensions/lib/customizer-controls/customizer-repeater-control/repeater-control.php on line 7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/amigo-extensions/lib/customizer-controls/customizer-repeater-control/inc/customizer.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/amigo-extensions/includes/industri/customizer/customizer.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/amigo-extensions/includes/aqwa/customizer/slider-customizer.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
4 plugin tags: corpox, industri, enron, aqwa

amigo-extensions/amigo-extensions.php 92% from 13 tests

"Amigo Extensions" version 1.0.16's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
You should first fix the following items:
  • Description: The description should be shorter than 140 characters (currently 417 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected9,673 lines of code in 67 files:
LanguageFilesBlank linesComment linesLines of code
PHP511,1859376,697
CSS7270311,812
JavaScript91621051,164

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity8.76
▷ Minimum class complexity1.00
▷ Maximum class complexity108.00
Average method complexity2.72
▷ Minimum method complexity1.00
▷ Maximum method complexity53.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes25
▷ Abstract classes00.00%
▷ Concrete classes25100.00%
▷ Final classes00.00%
Methods118
▷ Static methods2823.73%
▷ Public methods11093.22%
▷ Protected methods00.00%
▷ Private methods86.78%
Functions88
▷ Named functions4753.41%
▷ Anonymous functions4146.59%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
15 PNG files occupy 2.33MB with 0.78MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/industri/assets/images/elements/06.png6.87KB1.76KB▼ 74.36%
includes/aqwa/assets/images/elements-01.png4.00KB0.30KB▼ 92.60%
includes/industri/assets/images/elements/08.png365.45KB370.66KB0.00%
includes/industri/assets/images/slider/slider-01.png544.00KB545.47KB0.00%
includes/industri/assets/images/slider/slider-03.png677.30KB681.42KB0.00%