84% pmr-google-social-profiles-in-search-results

Code Review | PMR | Google Social Profiles

WordPress plugin PMR | Google Social Profiles scored84%from 54 tests.

About plugin

  • Plugin page: pmr-google-social...
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.1
  • WordPress version: 6.3.1
  • First release: Feb 25, 2015
  • Latest release: Apr 30, 2015
  • Number of updates: 15
  • Update frequency: every 4.2 days
  • Top authors: pmriley21 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /903 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼6.54ms] Passed 4 tests

Server-side resources used by PMR | Google Social Profiles
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0336.64 ▼0.30
Dashboard /wp-admin3.34 ▲0.0446.01 ▼1.60
Posts /wp-admin/edit.php3.39 ▲0.0343.86 ▼5.00
Add New Post /wp-admin/post-new.php5.92 ▲0.0382.35 ▼19.24
Media Library /wp-admin/upload.php3.26 ▲0.0336.14 ▲0.51

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

PMR | Google Social Profiles: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲7013.36 ▼1.321.71 ▲0.0338.21 ▼3.31
Dashboard /wp-admin2,222 ▲344.86 ▼1.05105.02 ▼0.1939.84 ▲1.30
Posts /wp-admin/edit.php2,102 ▲132.01 ▲0.0037.09 ▲3.1834.05 ▲0.51
Add New Post /wp-admin/post-new.php1,546 ▲2723.21 ▲0.16677.71 ▲20.0459.89 ▼4.73
Media Library /wp-admin/upload.php1,401 ▲134.21 ▼0.0798.02 ▼17.3543.88 ▼2.63

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
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

SRP 50% 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
Please fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/pmr-google-social-profiles-in-search-results/g_soc_prof.php

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)
Everything seems fine, but this is not an exhaustive test

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
Attributes that need to be fixed:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === pmr-google-social-profiles-in-search-results === )
Please take inspiration from this readme.txt

pmr-google-social-profiles-in-search-results/g_soc_prof.php 92% from 13 tests

"PMR | Google Social Profiles" version 1.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("pmr-google-social-profiles-in-search-results.php" instead of "g_soc_prof.php")

Code Analysis Passed 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
Success! There were no dangerous files found in this plugin125 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP13414125

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.09
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions5
▷ Named functions5100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
gsp_icon.png1.20KB0.29KB▼ 75.69%