84% mrz-social

Code Review | MRZ Social

WordPress plugin MRZ Social scored84%from 54 tests.

About plugin

  • Plugin page: mrz-social
  • Plugin version: 1.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-3.9.1
  • WordPress version: 6.3.1
  • First release: Mar 22, 2014
  • Latest release: Jul 22, 2014
  • Number of updates: 18
  • Update frequency: every 6.8 days
  • Top authors: MRazorZ (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /2,405 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼5.72ms] Passed 4 tests

Server-side resources used by MRZ Social
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1040.66 ▼3.53
Dashboard /wp-admin3.38 ▲0.0745.58 ▼2.48
Posts /wp-admin/edit.php3.49 ▲0.1343.05 ▼3.64
Add New Post /wp-admin/post-new.php5.96 ▲0.0781.80 ▼13.22
Media Library /wp-admin/upload.php3.30 ▲0.0734.95 ▼1.72

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 16 new files
Database: no new tables, 8 new options
New WordPress options
widget_mrz_social_icons_widget
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
widget_mrz_social_counter_widget
widget_recent-posts
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for MRZ Social
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲7113.20 ▼1.181.71 ▼0.3844.35 ▼1.17
Dashboard /wp-admin2,208 ▲205.86 ▼0.20100.13 ▼18.4038.52 ▼9.34
Posts /wp-admin/edit.php2,094 ▲51.99 ▼0.0236.19 ▲0.8131.63 ▼4.18
Add New Post /wp-admin/post-new.php1,516 ▼1723.05 ▼0.18683.49 ▼11.0156.89 ▼2.06
Media Library /wp-admin/upload.php1,390 ▼14.21 ▼0.0098.80 ▼2.3240.64 ▼4.56

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin did not uninstall successfully, leaving 8 options in the database
    • widget_theysaidso_widget
    • db_upgraded
    • widget_mrz_social_counter_widget
    • widget_mrz_social_icons_widget
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/mrz-social/includes/social-counter-widget.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/mrz-social/includes/options.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/mrz-social/includes/social-icons-widget.php:9

User-side errors Passed 1 test

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

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
These attributes need to be fixed:
  • Tags: Please delete some tags, you are using 14 tag instead of maximum 10
Please take inspiration from this readme.txt

mrz-social/mrz-social.php Passed 13 tests

"MRZ Social" version 1.1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
29 characters long description:
Friendly social links plugin.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Success! There were no dangerous files found in this plugin741 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP694246430
Sass2160207
PO File1232664
SVG10039
CSS1001

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity15.67
▷ Minimum class complexity9.00
▷ Maximum class complexity26.00
Average method complexity4.67
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods12
▷ Static methods00.00%
▷ Public methods12100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin