84% google-plus-authorship

Code Review | Google Plus Authorship

WordPress plugin Google Plus Authorship scored84%from 54 tests.

About plugin

  • Plugin page: google-plus-autho...
  • Plugin version: 2.6
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.7.1
  • WordPress version: 6.3.1
  • First release: Nov 19, 2012
  • Latest release: Jan 15, 2017
  • Number of updates: 12
  • Update frequency: every 126.5 days
  • Top authors: mlazarov (100%)

Code review

54 tests

User reviews

8 reviews

Install metrics

2,000+ active /85,390 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

Server-side resources used by Google Plus Authorship
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0333.86 ▼5.13
Dashboard /wp-admin3.33 ▲0.0244.09 ▲0.61
Posts /wp-admin/edit.php3.38 ▲0.0247.59 ▲2.39
Add New Post /wp-admin/post-new.php5.91 ▲0.0290.18 ▲4.74
Media Library /wp-admin/upload.php3.25 ▲0.0232.40 ▼2.72

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Google Plus Authorship
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.35 ▼0.001.71 ▲0.0436.22 ▼10.17
Dashboard /wp-admin2,198 ▲185.62 ▼0.0291.31 ▲3.6240.28 ▼1.13
Posts /wp-admin/edit.php2,103 ▲32.07 ▲0.0739.73 ▲4.2536.58 ▼3.16
Add New Post /wp-admin/post-new.php1,526 ▼023.52 ▲0.10600.93 ▼77.3554.11 ▼1.92
Media Library /wp-admin/upload.php1,391 ▼64.26 ▼0.0296.17 ▼19.5146.29 ▼2.07

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
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • 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
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
Please fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/google-plus-authorship/google-plus-authorhip.php:36

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 93% 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
Attributes that need to be fixed:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Google Plus Profile Picture in Google Search Result), #2 (Profile Page Setup), #3 (Rich Snippet Testing Tool)
The official readme.txt is a good inspiration

google-plus-authorship/google-plus-authorhip.php 92% from 13 tests

The entry point to "Google Plus Authorship" version 2.6 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("google-plus-authorship.php" instead of "google-plus-authorhip.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected61 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1171361

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.03
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
3 PNG files occupy 0.11MB with 0.07MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-3.png51.27KB19.83KB▼ 61.33%
screenshot-2.png43.71KB17.68KB▼ 59.56%
screenshot-1.png21.77KB9.67KB▼ 55.57%