10% wp-e-customers

Code Review | WP e-Customers Beta

WordPress plugin WP e-Customers Beta scored10%from 54 tests.

About plugin

  • Plugin page: wp-e-customers
  • Plugin version: 0.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.0-3.6.0
  • WordPress version: 6.3.1
  • First release: Sep 6, 2013
  • Latest release: Jan 19, 2017
  • Number of updates: 36
  • Update frequency: every 34.5 days
  • Top authors: WebTechGlobal (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,757 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Please fix the following installer errors
  • Install procedure had errors
    • > Deprecated in wp-content/plugins/wp-e-customers/functions/sections/downloads/wpecus_downloads_core.php+21
    Methods with the same name as their class will not be constructors in a future version of PHP; wpecus_downloads has a deprecated constructor

Server metrics [RAM: ▼0.94MB] [CPU: ▼44.48ms] Passed 4 tests

Analyzing server-side resources used by WP e-Customers Beta
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.05 ▼0.4212.32 ▼26.86
Dashboard /wp-admin3.07 ▼0.2315.24 ▼36.56
Posts /wp-admin/edit.php3.08 ▼0.2815.72 ▼28.56
Add New Post /wp-admin/post-new.php3.08 ▼2.8214.62 ▼85.95
Media Library /wp-admin/upload.php3.08 ▼0.1614.95 ▼20.92
Flag Item /wp-admin/post-new.php?post_type=wpecustomersflags3.0815.99
All Downloads /wp-admin/edit.php?post_type=downloads3.0815.22
All Flags /wp-admin/edit.php?post_type=wpecustomersflags3.0815.33
Add New /wp-admin/post-new.php?post_type=downloads3.0813.60

Server storage [IO: ▲3.04MB] [DB: ▲0.02MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 202 new files
Database: no new tables, 8 new options
New WordPress options
wpecus_adminset
can_compress_scripts
wpecus_tabmenu
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

WP e-Customers Beta: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,876 ▲13013.17 ▼1.211.88 ▲0.0748.05 ▲1.59
Dashboard /wp-admin2,276 ▲854.87 ▼0.2399.08 ▼0.2942.37 ▲1.84
Posts /wp-admin/edit.php2,156 ▲672.00 ▲0.0237.06 ▼1.7234.74 ▼0.96
Add New Post /wp-admin/post-new.php1,573 ▲4517.60 ▼0.55684.73 ▲50.8061.51 ▲5.89
Media Library /wp-admin/upload.php1,455 ▲644.24 ▼0.0797.71 ▼3.6744.21 ▼0.07
Flag Item /wp-admin/post-new.php?post_type=wpecustomersflags2,8267.82194.2771.29
All Downloads /wp-admin/edit.php?post_type=downloads1,1741.9330.1430.34
All Flags /wp-admin/edit.php?post_type=wpecustomersflags1,1232.0130.4431.37
Add New /wp-admin/post-new.php?post_type=downloads3,2137.84172.0073.00

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/wp-e-customers/functions/sections/downloads/wpecus_downloads_core.php+21
    Methods with the same name as their class will not be constructors in a future version of PHP; wpecus_downloads has a deprecated constructor
  • Zombie WordPress options detected upon uninstall: 8 options
    • db_upgraded
    • wpecus_adminset
    • wpecus_tabmenu
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Almost there, just fix the following server-side errors
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=downloads
    • > Deprecated in wp-content/plugins/wp-e-customers/functions/sections/downloads/wpecus_downloads_core.php+21
    Methods with the same name as their class will not be constructors in a future version of PHP; wpecus_downloads has a deprecated constructor
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=downloads
    • > Notice in wp-content/plugins/wp-e-customers/functions/wpecus_main_classes.php+37
    Undefined property: WPeCustomers::$WPeCus_core

SRP 0% 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
The following issues need your attention
  • 21× PHP files output non-empty strings when accessed directly via GET requests (only 10 are shown):
    • > /wp-content/plugins/wp-e-customers/views/forum/wpecus_forum_overview.php
    • > /wp-content/plugins/wp-e-customers/views/main/wpecus_about.php
    • > /wp-content/plugins/wp-e-customers/views/monetize/wpecus_monetize_overview.php
    • > /wp-content/plugins/wp-e-customers/views/users/wpecus_users_profile.php
    • > /wp-content/plugins/wp-e-customers/index.php
    • > /wp-content/plugins/wp-e-customers/views/index.php
    • > /wp-content/plugins/wp-e-customers/views/questions/wpecus_questions_overview.php
    • > /wp-content/plugins/wp-e-customers/functions/index.php
    • > /wp-content/plugins/wp-e-customers/views/finance/wpecus_finance_overview.php
    • > /wp-content/plugins/wp-e-customers/wtg-core/wp/css/index.php
  • 84× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wpecus_create_adminurl() in wp-content/plugins/wp-e-customers/views/downloads/wpecus_downloads_library.php:26
    • > PHP Fatal error
      Uncaught Error: Class 'WPeCus_lab_core' not found in wp-content/plugins/wp-e-customers/functions/sections/monetize/wpecus_monetize_core.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'WPeCus_community_ui' not found in wp-content/plugins/wp-e-customers/functions/sections/downloads/wpecus_downloads_ui.php:10
    • > PHP Notice
      Trying to get property 'user_login' of non-object in wp-content/plugins/wp-e-customers/views/users/wpecus_users_profile.php on line 44
    • > PHP Fatal error
      Uncaught Error: Class 'WPeCus_tickets_core' not found in wp-content/plugins/wp-e-customers/functions/sections/users/wpecus_users_core.php:9
    • > PHP Fatal error
      require_once(): Failed opening required 'WTG_WPECUS_PATHfunctions/sections/clients/wpecus_clients_processing.php' (include_path='.:/usr/share/php') in wp-content/plugins/wp-e-customers/processing/wpecus_form_one.php on line 14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wpecus_header_page() in wp-content/plugins/wp-e-customers/views/users/wpecus_main_users.php:28
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wpecus_header_page() in wp-content/plugins/wp-e-customers/views/affiliates/wpecus_main_affiliates.php:28
    • > PHP Fatal error
      Uncaught Error: Class 'WPeCus_downloads_ui' not found in wp-content/plugins/wp-e-customers/functions/sections/faq/wpecus_faq_ui.php:10
    • > PHP Notice
      Undefined variable: panel_number in wp-content/plugins/wp-e-customers/views/main/wpecus_generalsettings.php on line 12

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 93% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
  • Tags: Please delete some tags, you are using 14 tag instead of maximum 10
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === wp-e-customers === )
You can look at the official readme.txt

wp-e-customers/wp-e-customers.php Passed 13 tests

This is the main PHP file of "WP e-Customers Beta" version 0.0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
62 characters long description:
WP e-Customers plugin is the ultimate online business solution

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected9,530 lines of code in 152 files:
LanguageFilesBlank linesComment linesLines of code
PHP1492,6804,3388,961
CSS38252569

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity1.61
▷ Minimum class complexity1.00
▷ Maximum class complexity32.00
Average method complexity2.76
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes61
▷ Abstract classes11.64%
▷ Concrete classes6098.36%
▷ Final classes00.00%
Methods21
▷ Static methods00.00%
▷ Public methods1885.71%
▷ Protected methods29.52%
▷ Private methods14.76%
Functions322
▷ Named functions322100.00%
▷ Anonymous functions00.00%
Constants16
▷ Global constants16100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
27 PNG files occupy 2.32MB with 2.08MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
wtg-core/images/warning_extra.png105.76KB10.47KB▼ 90.10%
wtg-core/images/error_large.png62.46KB5.79KB▼ 90.72%
wtg-core/images/stop_extra.png140.76KB16.99KB▼ 87.93%
wtg-core/images/restricted_extra.png124.49KB14.43KB▼ 88.41%
wtg-core/images/step_large.png60.62KB5.37KB▼ 91.14%