63% aspose-contact-form

Code Review | Aspose Contact Form

WordPress plugin Aspose Contact Form scored63%from 54 tests.

About plugin

  • Plugin page: aspose-contact-form
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.8
  • WordPress version: 6.3.1
  • First release: Dec 8, 2021
  • Latest release: Dec 22, 2021
  • Number of updates: 11
  • Update frequency: every 1.3 days
  • Top authors: asposemarketplace (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /343 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
Install script ran successfully

Server metrics [RAM: ▲0.30MB] [CPU: ▼2.75ms] Passed 4 tests

A check of server-side resources used by Aspose Contact Form
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.78 ▲0.3239.77 ▼1.84
Dashboard /wp-admin3.63 ▲0.3350.41 ▼0.97
Posts /wp-admin/edit.php3.69 ▲0.3346.87 ▼4.01
Add New Post /wp-admin/post-new.php6.15 ▲0.2784.82 ▼4.19
Media Library /wp-admin/upload.php3.50 ▲0.2736.78 ▲3.41
Form using MS Excel /wp-admin/admin.php?page=aspose-contact-form/excel-to-form-admin.php3.4635.23
Aspose Form /wp-admin/admin.php?page=aspose-contact-form3.4636.82
Aspose Contact Form /wp-admin/options-general.php?page=apc-excel-to-form-settings3.4632.98

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 525 new files
Database: 2 new tables, 7 new options
New tables
wp_apc_shortcodes
wp_aspose_forms
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
aspose-cloud-activation-secret
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Aspose Contact Form
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,831 ▲9613.41 ▼0.791.62 ▼0.1540.88 ▼4.14
Dashboard /wp-admin2,237 ▲495.92 ▲0.86101.54 ▼3.4638.77 ▼5.49
Posts /wp-admin/edit.php2,128 ▲392.22 ▲0.2435.36 ▼1.9833.69 ▲1.48
Add New Post /wp-admin/post-new.php1,552 ▲3218.19 ▼5.17688.87 ▲3.9162.05 ▲0.76
Media Library /wp-admin/upload.php1,430 ▲424.30 ▲0.0798.33 ▼3.2142.71 ▼3.48
Form using MS Excel /wp-admin/admin.php?page=aspose-contact-form/excel-to-form-admin.php9701.9226.4331.32
Aspose Form /wp-admin/admin.php?page=aspose-contact-form1,0572.0424.0135.06
Aspose Contact Form /wp-admin/options-general.php?page=apc-excel-to-form-settings9001.8824.6331.82

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie tables detected upon uninstall: 2 tables
    • wp_aspose_forms
    • wp_apc_shortcodes
  • Zombie WordPress options detected upon uninstall: 7 options
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • aspose-cloud-activation-secret

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 202× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Aspose\\Cells\\Cloud\\Model\\CellsCloudResponse' not found in wp-content/plugins/aspose-contact-form/vendor/aspose/cells-sdk-php/lib/Model/AutoShapeResponse.php:53
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Handler\\CurlFactoryInterface' not found in wp-content/plugins/aspose-contact-form/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'Lcobucci\\JWT\\Signer' not found in wp-content/plugins/aspose-contact-form/vendor/lcobucci/jwt/src/Signer/BaseSigner.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit\\Framework\\TestCase' not found in wp-content/plugins/aspose-contact-form/vendor/lcobucci/jwt/test/unit/Signer/HmacTest.php:14
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/aspose-contact-form/vendor/guzzlehttp/promises/src/Coroutine.php:45
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromiseInterface' not found in wp-content/plugins/aspose-contact-form/vendor/guzzlehttp/promises/src/Promise.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Aspose\\Cells\\Cloud\\Model\\CellsCloudResponse' not found in wp-content/plugins/aspose-contact-form/vendor/aspose/cells-sdk-php/lib/Model/ValidationResponse.php:53
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit\\Framework\\TestCase' not found in wp-content/plugins/aspose-contact-form/vendor/lcobucci/jwt/test/unit/Signer/RsaTest.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'Aspose\\Cells\\Cloud\\Model\\SaveOptions' not found in wp-content/plugins/aspose-contact-form/vendor/aspose/cells-sdk-php/lib/Model/MHtmlSaveOptions.php:53
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/aspose-contact-form/vendor/guzzlehttp/psr7/src/AppendStream.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

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
Attributes that require attention: You can look at the official readme.txt

aspose-contact-form/aspose-contact-form.php Passed 13 tests

The main file in "Aspose Contact Form" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
131 characters long description:
Aspose Contact Form Plugin for WordPress allows site administrators/ownwers to create interactive forms using Microsoft Excel files

Code Analysis 0% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
It is important to fix the following items
  • For security reasons, never distribute binary or executable files with your plugin
    • .bat - Batch File in Windows
      • wp-content/plugins/aspose-contact-form/vendor/aspose/cells-sdk-php/composer.bat
135,661 lines of code in 499 files:
LanguageFilesBlank linesComment linesLines of code
PHP45757,784146,403129,230
Markdown151,18503,598
JavaScript32451921,228
JSON11001,174
XML520293
YAML33078
Bourne Shell113831
Dockerfile18010
make1409
CSS1196
DOS Batch1004

PHP code 0% from 2 tests

This is a very shot review of cyclomatic complexity and code structure
The following items need your attention
  • Cyclomatic complexity of classes should be reduced to less than 1000 (currently 8,642)
  • Cyclomatic complexity of methods should be reduced to less than 100 (currently 179)
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity31.46
▷ Minimum class complexity1.00
▷ Maximum class complexity8,642.00
Average method complexity2.53
▷ Minimum method complexity1.00
▷ Maximum method complexity179.00
Code structure
Namespaces24
Interfaces20
Traits3
Classes395
▷ Abstract classes51.27%
▷ Concrete classes39098.73%
▷ Final classes287.18%
Methods8,538
▷ Static methods1,40616.47%
▷ Public methods8,10894.96%
▷ Protected methods2733.20%
▷ Private methods1571.84%
Functions956
▷ Named functions939.73%
▷ Anonymous functions86390.27%
Constants420
▷ Global constants4210.00%
▷ Class constants37890.00%
▷ Public constants378100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There are no PNG files in this plugin