78% youzify

Code Review | Youzify – BuddyPress Community, User Profile, Social Network & Membership Plugin for WordPress

WordPress plugin Youzify – BuddyPress Community, User Profile, Social Network & Membership Plugin for WordPress scored78%from 54 tests.

About plugin

  • Plugin page: youzify
  • Plugin version: 1.2.3
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.3
  • WordPress version: 6.3.1
  • First release: Mar 5, 2021
  • Latest release: Sep 18, 2023
  • Number of updates: 68
  • Update frequency: every 15.1 days
  • Top authors: youzify (100%)

Code review

54 tests

User reviews

148 reviews

Install metrics

9,000+ active /82,353 total downloads

Benchmarks

Plugin footprint 83% 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.00MB] [CPU: ▼5.48ms] Passed 4 tests

An overview of server-side resources used by Youzify – BuddyPress Community, User Profile, Social Network & Membership Plugin for WordPress
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0136.67 ▼13.49
Dashboard /wp-admin3.31 ▲0.0044.35 ▼4.96
Posts /wp-admin/edit.php3.36 ▲0.0049.59 ▲5.81
Add New Post /wp-admin/post-new.php5.89 ▲0.0090.29 ▲0.23
Media Library /wp-admin/upload.php3.23 ▲0.0034.96 ▼3.70

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 845 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

Youzify – BuddyPress Community, User Profile, Social Network & Membership Plugin for WordPress: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,808 ▲7313.23 ▼1.031.61 ▼0.2739.62 ▼8.36
Dashboard /wp-admin2,214 ▲265.81 ▲0.9597.38 ▼4.1540.58 ▼2.72
Posts /wp-admin/edit.php2,096 ▲71.98 ▼0.0540.22 ▲1.4434.58 ▲2.63
Add New Post /wp-admin/post-new.php1,557 ▲2323.50 ▲0.47587.73 ▼90.2256.11 ▲1.07
Media Library /wp-admin/upload.php1,396 ▲144.22 ▲0.0593.81 ▼3.9143.39 ▼2.02

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options

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 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/youzify/includes/public/templates/members/single/events/attending.php
    • > /wp-content/plugins/youzify/includes/public/templates/members/single/posts.php
  • 296× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Hybridauth\\Adapter\\OpenID' not found in wp-content/plugins/youzify/includes/public/core/hybridauth/Provider/StackExchangeOpenID.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'Hybridauth\\Provider\\Blizzard' not found in wp-content/plugins/youzify/includes/public/core/hybridauth/Provider/BlizzardAPAC.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'Hybridauth\\Exception\\InvalidArgumentException' not found in wp-content/plugins/youzify/includes/public/core/hybridauth/Exception/InvalidOpenidIdentifierException.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function do_action() in wp-content/plugins/youzify/includes/public/templates/members/single/woocommerce/edit-address.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/youzify/includes/premium/public/core/activity/class-youzify-sticky-posts.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/youzify/includes/public/templates/members/single/notifications/notifications-loop.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/youzify/includes/public/core/membership/class-youzify-limit.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/youzify/includes/public/core/mycred/youzify-mycred-functions.php:22
    • > PHP Fatal error
      Uncaught Error: Call to undefined function do_action() in wp-content/plugins/youzify/includes/public/templates/members/single/activity.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'Hybridauth\\Adapter\\OAuth2' not found in wp-content/plugins/youzify/includes/public/core/hybridauth/Provider/Pinterest.php:18

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need your attention:
  • Tags: You are using too many tags: 15 tag instead of maximum 10
The official readme.txt is a good inspiration

youzify/youzify.php 92% from 13 tests

The main PHP script in "Youzify – BuddyPress Community, User Profile, Social Network & Membership Plugin for WordPress" version 1.2.3 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 358 characters long)

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin176,219 lines of code in 701 files:
LanguageFilesBlank linesComment linesLines of code
PO File1025,18948,56061,338
PHP47120,11016,71452,667
CSS1018,0282,24339,757
JavaScript1063,1032,17711,776
SVG80310,616
XML10046
Markdown310018
HTML1001

PHP code 50% from 2 tests

A short review of cyclomatic complexity and code structure
The following items need your attention
  • Cyclomatic complexity of methods should be reduced to less than 100 (currently 127)
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity18.06
▷ Minimum class complexity1.00
▷ Maximum class complexity207.00
Average method complexity4.11
▷ Minimum method complexity1.00
▷ Maximum method complexity127.00
Code structure
Namespaces11
Interfaces5
Traits1
Classes223
▷ Abstract classes52.24%
▷ Concrete classes21897.76%
▷ Final classes52.29%
Methods1,297
▷ Static methods594.55%
▷ Public methods1,16890.05%
▷ Protected methods1158.87%
▷ Private methods141.08%
Functions755
▷ Named functions74598.68%
▷ Anonymous functions101.32%
Constants24
▷ Global constants1875.00%
▷ Class constants625.00%
▷ Public constants6100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
114 PNG files occupy 0.29MB with 0.09MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/admin/assets/images/imgSelect/youzify-pink-scheme.png1.17KB1.21KB0.00%
includes/admin/assets/images/imgSelect/youzify-white-scheme.png2.28KB0.96KB▼ 58.07%
includes/admin/assets/images/imgSelect/radius.png0.32KB0.19KB▼ 39.14%
includes/admin/assets/images/imgSelect/author-box-v5.png0.50KB0.35KB▼ 30.49%
includes/admin/assets/images/imgSelect/form-field-v9.png0.62KB0.43KB▼ 29.79%