83% socialproofus

Code Review | SocialProofus Notifications

WordPress plugin SocialProofus Notifications scored83%from 54 tests.

About plugin

  • Plugin page: socialproofus
  • Plugin version: 1.0.5
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.4
  • WordPress version: 6.3.1
  • First release: Jan 16, 2023
  • Latest release: Nov 10, 2023
  • Number of updates: 26
  • Update frequency: every 11.5 days
  • Top authors: wizz99 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /632 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
Install script ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼6.47ms] Passed 4 tests

Analyzing server-side resources used by SocialProofus Notifications
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0234.65 ▼6.19
Dashboard /wp-admin3.33 ▼0.0145.20 ▼15.06
Posts /wp-admin/edit.php3.38 ▲0.0347.47 ▲2.15
Add New Post /wp-admin/post-new.php5.91 ▲0.0382.98 ▼6.77
Media Library /wp-admin/upload.php3.26 ▲0.0334.82 ▲6.60

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

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

Browser metrics Passed 4 tests

A check of browser resources used by SocialProofus Notifications
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,847 ▲10014.34 ▲0.081.97 ▲0.1335.82 ▼8.66
Dashboard /wp-admin2,220 ▲435.59 ▼0.0287.55 ▼5.5039.32 ▼4.74
Posts /wp-admin/edit.php2,129 ▲292.02 ▲0.0240.67 ▲4.0837.77 ▲1.98
Add New Post /wp-admin/post-new.php1,547 ▲2123.44 ▲0.37594.76 ▼110.0851.15 ▼0.69
Media Library /wp-admin/upload.php1,431 ▲284.22 ▲0.0396.93 ▼0.1141.51 ▼1.22

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
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

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
Please fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/socialproofus/socialproofus.php:15

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

readme.txt 81% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Screenshots: Please add descriptions for these screenshots #1, #2, #3, #4 in socialproofus/assets to your readme.txt
  • Contributors: Contributors not specified
  • Tags: You are using too many tags: 13 tag instead of maximum 10
The official readme.txt is a good inspiration

socialproofus/socialproofus.php 92% from 13 tests

The main PHP script in "SocialProofus Notifications" version 1.0.5 is automatically included on every request by WordPress
The following require your attention:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin117 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP22720117

PHP code Passed 2 tests

Analyzing 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.05
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods4100.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions7
▷ Named functions7100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
1 PNG file occupies 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
includes/assets/top-logo.png18.26KB7.78KB▼ 57.38%