72% linkedin-profile-badge

Code Review | Linkedin Profile Badge

WordPress plugin Linkedin Profile Badge scored 72% from 54 tests.

About plugin

  • Plugin page: linkedin-profile-...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 2.7-3.4.2
  • WordPress version: 6.3.1
  • First release: Nov 28, 2012
  • Latest release: Nov 28, 2012
  • Number of updates: 10
  • Update frequency: every 0.5 days
  • Top authors: alexmoss (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active / 9,195 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

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

Server-side resources used by Linkedin Profile Badge
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0134.44 ▼7.90
Dashboard /wp-admin3.35 ▲0.0450.89 ▲6.08
Posts /wp-admin/edit.php3.40 ▲0.0445.60 ▲0.18
Add New Post /wp-admin/post-new.php5.93 ▲0.0485.74 ▼6.85
Media Library /wp-admin/upload.php3.27 ▲0.0438.70 ▲1.97
Linkedin Profile Badge /wp-admin/options-general.php?page=linkedinbadge3.31417.34

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
linkedinbadge
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Linkedin Profile Badge
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,847 ▲11214.49 ▲0.2259.68 ▲58.0137.59 ▼7.47
Dashboard /wp-admin2,217 ▲295.86 ▼0.0296.59 ▼8.6443.34 ▲0.37
Posts /wp-admin/edit.php2,102 ▲162.01 ▲0.0234.23 ▼4.3434.58 ▲1.57
Add New Post /wp-admin/post-new.php1,546 ▲423.16 ▲4.57664.41 ▲47.0857.05 ▲3.23
Media Library /wp-admin/upload.php1,402 ▲114.22 ▲0.03110.30 ▼1.5347.36 ▼1.48
Linkedin Profile Badge /wp-admin/options-general.php?page=linkedinbadge1,4657.76229.9470.35

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • This plugin does not fully uninstall, leaving 7 options in the database
    • widget_theysaidso_widget
    • linkedinbadge
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These server-side errors were triggered
    • > GET request to /wp-admin/options-general.php?page=linkedinbadge
    • > Warning in wp-content/plugins/linkedin-profile-badge/class-admin.php+236
    Invalid argument supplied for foreach()

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 server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/linkedin-profile-badge/linkedin-profile-badge.php:22
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/linkedin-profile-badge/class-admin.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/linkedin-profile-badge/class-frontend.php:11

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Please fix the following browser errors
    • > GET request to /wp-admin/options-general.php?page=linkedinbadge
    • > Network (severe)
    http://platform.stumbleupon.com/1/widgets.js - Failed to load resource: net::ERR_NAME_NOT_RESOLVED
    • > GET request to /wp-admin/options-general.php?page=linkedinbadge
    • > Javascript (severe) in unknown
    https://button.buffer.com/button/?id=378cca86f6deae22&url=http%3A%2F%2F3doordigital.com%2Fwordpress%2Fplugins%2Flinkedin-profile-badge%2F&text=Just%20been%20using%20Linkedin%20Profile%20Badge%20%23WordPress%20plugin&via=alexmoss&count=horizontal&placement=button&utm_source=http%3A%2F%2Fwp.com%2Fwp-admin%2Foptions-general.php%3Fpage%3Dlinkedinbadge&utm_medium=buffer_button&utm_campaign=buffer 15:647 Uncaught TypeError: Cannot set properties of null (setting 'onclick')
    • > GET request to /wp-admin/options-general.php?page=linkedinbadge
    • > Other (severe) in unknown
    chrome-error://chromewebdata/ - Refused to display 'https://developers.google.com/' in a frame because it set 'X-Frame-Options' to 'sameorigin'.

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
7 plugin tags: profile, post, shortcode, linkedin, page...

linkedin-profile-badge/linkedin-profile-badge.php 92% from 13 tests

The primary PHP file in "Linkedin Profile Badge" version 1.0 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Description: The description should be shorter than 140 characters (currently 228 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected362 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP34119261
CSS1120101

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.24
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%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
3dd-logo.png14.63KB5.34KB▼ 63.49%