78% weldpress

Code Review | WeldPress

WordPress plugin WeldPress scored78%from 54 tests.

About plugin

  • Plugin page: weldpress
  • Plugin version: 4.9
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-4.3.1
  • WordPress version: 6.3.1
  • First release: Apr 21, 2017
  • Latest release: Jul 6, 2017
  • Number of updates: 10
  • Update frequency: every 9.0 days
  • Top authors: weldpad (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /612 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲1.34MB] [CPU: ▲2.25ms] Passed 4 tests

A check of server-side resources used by WeldPress
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /4.76 ▲1.3052.42 ▲10.03
Dashboard /wp-admin4.71 ▲1.3754.17 ▼3.31
Posts /wp-admin/edit.php4.76 ▲1.4155.60 ▲4.79
Add New Post /wp-admin/post-new.php7.25 ▲1.3790.06 ▼2.52
Media Library /wp-admin/upload.php4.57 ▲1.3546.35 ▲13.37
Integration /wp-admin/admin.php?page=WELDPRESS-integration4.5539.06
WeldPress Solution /wp-admin/admin.php?page=WELDPRESS4.6840.95
Add New /wp-admin/admin.php?page=WELDPRESS-new4.64287.08

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 76 new files
Database: no new tables, 7 new options
New WordPress options
WELDPRESS
can_compress_scripts
widget_recent-posts
widget_recent-comments
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by WeldPress
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,950 ▲20413.78 ▼0.6310.78 ▲9.1342.83 ▲0.09
Dashboard /wp-admin2,213 ▲395.56 ▼0.0180.84 ▼5.6040.22 ▲0.50
Posts /wp-admin/edit.php2,127 ▲242.04 ▲0.0234.65 ▼5.1934.98 ▼2.58
Add New Post /wp-admin/post-new.php1,548 ▲1723.18 ▲0.16671.41 ▲19.3755.41 ▲1.62
Media Library /wp-admin/upload.php1,427 ▲274.17 ▲0.02102.13 ▲7.1343.50 ▲0.44
Integration /wp-admin/admin.php?page=WELDPRESS-integration9052.3035.5427.61
WeldPress Solution /wp-admin/admin.php?page=WELDPRESS1,2782.0030.3739.18
Add New /wp-admin/admin.php?page=WELDPRESS-new8981.546.9220.81

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/weldpress/admin/edit-contact-form.php
  • 34× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/weldpress/modules/really-simple-captcha.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/weldpress/modules/checkbox.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/weldpress/modules/select.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/weldpress/modules/akismet.php:7
    • > PHP Fatal error
      require_once(): Failed opening required 'WELD_PRESS_PLUGIN_DIR/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/weldpress/settings.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'WELD_PRESS_FormTag' not found in wp-content/plugins/weldpress/includes/shortcodes.php:94
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/weldpress/modules/flamingo.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/weldpress/modules/response.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/weldpress/modules/count.php:8
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/weldpress/admin/includes/class-contact-forms-list-table.php on line 4

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 issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
6 plugin tags: iot, component, directive, code, javascript...

weldpress/weldpress.php 85% from 13 tests

The main PHP file in "WeldPress" ver. 4.9 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 203 characters long)
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin11,131 lines of code in 58 files:
LanguageFilesBlank linesComment linesLines of code
PHP462,4901957,619
CSS71421161,927
JavaScript53082511,585

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity22.29
▷ Minimum class complexity1.00
▷ Maximum class complexity114.00
Average method complexity3.12
▷ Minimum method complexity1.00
▷ Maximum method complexity28.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes21
▷ Abstract classes14.76%
▷ Concrete classes2095.24%
▷ Final classes00.00%
Methods213
▷ Static methods2612.21%
▷ Public methods17783.10%
▷ Protected methods10.47%
▷ Private methods3516.43%
Functions229
▷ Named functions229100.00%
▷ Anonymous functions00.00%
Constants25
▷ Global constants1768.00%
▷ Class constants832.00%
▷ Public constants8100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
13 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/js/jquery-ui/themes/smoothness/images/ui-bg_flat_0_aaaaaa_40x100.png0.21KB0.08KB▼ 58.96%
includes/js/jquery-ui/themes/smoothness/images/ui-icons_888888_256x240.png6.83KB4.17KB▼ 38.92%
includes/js/jquery-ui/themes/smoothness/images/ui-icons_454545_256x240.png6.83KB4.17KB▼ 38.86%
includes/js/jquery-ui/themes/smoothness/images/ui-bg_flat_75_ffffff_40x100.png0.20KB0.08KB▼ 58.17%
includes/js/jquery-ui/themes/smoothness/images/ui-bg_glass_95_fef1ec_1x400.png0.32KB0.15KB▼ 54.82%