79% lsx-team

Code Review | LSX Team

WordPress plugin LSX Team scored79%from 54 tests.

About plugin

  • Plugin page: lsx-team
  • Plugin version: 1.3.5
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Mar 5, 2018
  • Latest release: Aug 18, 2023
  • Number of updates: 38
  • Update frequency: every 52.4 days
  • Top authors: feedmymedia (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,075 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲1.11MB] [CPU: ▲6.89ms] Passed 4 tests

A check of server-side resources used by LSX Team
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /4.29 ▲0.8247.70 ▲6.22
Dashboard /wp-admin4.54 ▲1.2461.41 ▲7.52
Posts /wp-admin/edit.php4.56 ▲1.2065.18 ▲17.77
Add New Post /wp-admin/post-new.php7.17 ▲1.29100.54 ▼1.49
Media Library /wp-admin/upload.php4.40 ▲1.1751.15 ▲15.31
Settings /wp-admin/edit.php?post_type=team&page=lsx_team_options4.8458.02
Roles /wp-admin/edit-tags.php?taxonomy=team_role&post_type=team4.4048.58
All Team Members /wp-admin/edit.php?post_type=team4.5150.81
Add New /wp-admin/post-new.php?post_type=team5.8556.37

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 428 new files
Database: no new tables, 8 new options
New WordPress options
can_compress_scripts
db_upgraded
theysaidso_admin_options
lsx_team_scporder_install
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
widget_lsx_team_widget

Browser metrics Passed 4 tests

An overview of browser requirements for LSX Team
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,932 ▲17113.50 ▼0.868.00 ▲6.3539.13 ▼6.20
Dashboard /wp-admin2,245 ▲715.74 ▲0.0887.76 ▼1.9339.87 ▼2.40
Posts /wp-admin/edit.php2,167 ▲672.30 ▲0.2739.91 ▼1.1633.93 ▼2.94
Add New Post /wp-admin/post-new.php1,568 ▲3123.31 ▲5.09643.95 ▲6.4660.91 ▼13.20
Media Library /wp-admin/upload.php1,460 ▲634.31 ▲0.08107.80 ▲10.1941.76 ▼1.97
Settings /wp-admin/edit.php?post_type=team&page=lsx_team_options1,2553.3350.1630.50
Roles /wp-admin/edit-tags.php?taxonomy=team_role&post_type=team1,3602.3538.0929.68
All Team Members /wp-admin/edit.php?post_type=team1,1592.4538.9227.58
Add New /wp-admin/post-new.php?post_type=team6,44419.46850.7341.01

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Zombie WordPress options were found after uninstall: 8 options
    • widget_recent-posts
    • lsx_team_scporder_install
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_lsx_team_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These errors were triggered by the plugin
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=team
    • > Notice in wp-content/plugins/lsx-team/includes/functions.php+107
    Trying to get property 'id' of non-object
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=team
    • > Notice in wp-content/plugins/lsx-team/includes/functions.php+108
    Trying to access array offset on value of type bool

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 fix the following
  • 54× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Multi_Base' not found in wp-content/plugins/lsx-team/vendor/CMB2/includes/types/CMB2_Type_Taxonomy_Base.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function team_get_option() in wp-content/plugins/lsx-team/templates/content-archive-team-careers-cta.php:7
    • > PHP Warning
      Use of undefined constant LSX_TEAM_PATH - assumed 'LSX_TEAM_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/lsx-team/classes/class-lsx-team-admin.php on line 35
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Taxonomy_Multicheck' not found in wp-content/plugins/lsx-team/vendor/CMB2/includes/types/CMB2_Type_Taxonomy_Multicheck_Hierarchical.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Picker_Base' not found in wp-content/plugins/lsx-team/vendor/CMB2/includes/types/CMB2_Type_Text_Date.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/lsx-team/classes/class-lsx-team-widget.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_File_Base' not found in wp-content/plugins/lsx-team/vendor/CMB2/includes/types/CMB2_Type_File_List.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Taxonomy_Radio' not found in wp-content/plugins/lsx-team/vendor/CMB2/includes/types/CMB2_Type_Taxonomy_Radio_Hierarchical.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Text' not found in wp-content/plugins/lsx-team/vendor/CMB2/includes/types/CMB2_Type_Oembed.php:13
    • > PHP Fatal error
      Uncaught Error: Call to a member function get_thumbnail() on null in wp-content/plugins/lsx-team/templates/content-single-team.php:10

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
5 plugin tags: team members, team, lsx, our team, block editor support

lsx-team/lsx-team.php Passed 13 tests

The main PHP script in "LSX Team" version 1.3.5 is automatically included on every request by WordPress
124 characters long description:
The LSX Team extension provides a custom post type that allows you to easily show off the people that make up your business.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected52,182 lines of code in 268 files:
LanguageFilesBlank linesComment linesLines of code
PO File12114,41418,60432,540
PHP722,5616,5679,122
CSS215371,1974,859
Sass234933562,352
JavaScript174307331,826
Markdown43060826
XML6139472
YAML450185

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.46
Average class complexity20.58
▷ Minimum class complexity1.00
▷ Maximum class complexity186.00
Average method complexity3.45
▷ Minimum method complexity1.00
▷ Maximum method complexity48.00
Code structure
Namespaces2
Interfaces0
Traits0
Classes78
▷ Abstract classes911.54%
▷ Concrete classes6988.46%
▷ Final classes00.00%
Methods627
▷ Static methods9414.99%
▷ Public methods53385.01%
▷ Protected methods8914.19%
▷ Private methods50.80%
Functions32
▷ Named functions32100.00%
▷ Anonymous functions00.00%
Constants14
▷ Global constants750.00%
▷ Class constants750.00%
▷ Public constants7100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
15 compressed PNG files occupy 0.02MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
vendor/CMB2/images/ui-bg_glass_55_fbf9ee_1x400.png0.12KB0.14KB0.00%
vendor/CMB2/images/ui-bg_glass_95_fef1ec_1x400.png0.12KB0.14KB0.00%
vendor/CMB2/images/ui-bg_glass_75_dadada_1x400.png0.11KB0.16KB0.00%
vendor/CMB2/images/ui-icons_cd0a0a_256x240.png4.27KB4.11KB▼ 3.78%
vendor/CMB2/images/ui-icons_2e83ff_256x240.png4.27KB4.11KB▼ 3.78%