84% asura-connector

Code Review | Asura Connector

WordPress plugin Asura Connector scored 84% from 54 tests.

About plugin

  • Plugin page: asura-connector
  • Plugin version: 4.1.0
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5-5.8
  • WordPress version: 5.8.1
  • First release: Dec 25, 2020
  • Latest release: Sep 17, 2021
  • Number of updates: 29
  • Update frequency: every 9.2 days
  • Top authors: thelostasura (55.17%)oxyrealm (48.28%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active / 1,010 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

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

A check of server-side resources used by Asura Connector
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.1334.78 ▲13.22
Dashboard /wp-admin3.08 ▲0.0247.93 ▲10.40
Posts /wp-admin/edit.php3.13 ▲0.0245.32 ▲1.15
Add New Post /wp-admin/post-new.php5.44 ▲0.0084.44 ▼558.34
Media Library /wp-admin/upload.php3.02 ▲0.0230.09 ▼4.84
Asura Connector /wp-admin/admin.php?page=aether_m_connector2.9929.59

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 204 new files
Database: 2 new tables, 3 new options
New tables
wp_asura_connector_licenses
wp_asura_connector_providers
New WordPress options
asura_connector_installed
asura_connector_db_version
asura_connector_version

Browser metrics Passed 4 tests

A check of browser resources used by Asura Connector
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,703 ▲10716.11 ▲0.578.97 ▼1.8553.73 ▲7.04
Dashboard /wp-admin2,973 ▲396.11 ▼0.03152.26 ▼5.86103.31 ▼5.80
Posts /wp-admin/edit.php2,739 ▼02.73 ▲0.0263.94 ▼18.1987.56 ▼5.85
Add New Post /wp-admin/post-new.php1,683 ▼018.35 ▼0.34422.13 ▲34.75105.83 ▲0.34
Media Library /wp-admin/upload.php1,807 ▼35.01 ▼0.05160.47 ▲12.36116.29 ▲2.19
Asura Connector /wp-admin/admin.php?page=aether_m_connector1,0993.5386.9457.48

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie tables detected upon uninstall: 2 tables
    • wp_asura_connector_licenses
    • wp_asura_connector_providers

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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 fix the following
  • 64× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Medoo\\Tests\\MedooTestCase' not found in wp-content/plugins/asura-connector/vendor/catfan/medoo/tests/DropTest.php:8
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Handler\\CurlFactoryInterface' not found in wp-content/plugins/asura-connector/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'Medoo\\Tests\\MedooTestCase' not found in wp-content/plugins/asura-connector/vendor/catfan/medoo/tests/SelectTest.php:11
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromisorInterface' not found in wp-content/plugins/asura-connector/vendor/guzzlehttp/guzzle/src/Pool.php:24
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/asura-connector/vendor/guzzlehttp/promises/src/Coroutine.php:45
    • > PHP Fatal error
      Uncaught Error: Class 'Medoo\\Tests\\MedooTestCase' not found in wp-content/plugins/asura-connector/vendor/catfan/medoo/tests/QueryTest.php:10
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Client\\ClientExceptionInterface' not found in wp-content/plugins/asura-connector/vendor/psr/http-client/src/NetworkExceptionInterface.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit\\Framework\\TestCase' not found in wp-content/plugins/asura-connector/vendor/catfan/medoo/tests/MedooTestCase.php:8
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\RequestInterface' not found in wp-content/plugins/asura-connector/vendor/guzzlehttp/psr7/src/Request.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Client\\ClientExceptionInterface' not found in wp-content/plugins/asura-connector/vendor/psr/http-client/src/RequestExceptionInterface.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
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
6 plugin tags: woocommerce, oxygen builder, design set, ecommerce, easy digital download...

asura-connector/asura-connector.php 92% from 13 tests

"Asura Connector" version 4.1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Domain Path: The domain path folder was not found ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin19,286 lines of code in 186 files:
LanguageFilesBlank linesComment linesLines of code
PHP1563,4917,32015,026
Markdown161,19803,596
JSON200551
YAML310140
JavaScript41134
XML11021
make1409
SVG2008
CSS1001

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity15.02
▷ Minimum class complexity1.00
▷ Maximum class complexity359.00
Average method complexity2.85
▷ Minimum method complexity1.00
▷ Maximum method complexity56.00
Code structure
Namespaces18
Interfaces26
Traits3
Classes115
▷ Abstract classes00.00%
▷ Concrete classes115100.00%
▷ Final classes3429.57%
Methods1,040
▷ Static methods20719.90%
▷ Public methods89686.15%
▷ Protected methods232.21%
▷ Private methods12111.63%
Functions142
▷ Named functions3323.24%
▷ Anonymous functions10976.76%
Constants70
▷ Global constants11.43%
▷ Class constants6998.57%
▷ Public constants5884.06%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected