78% site-name-for-google-search

Code Review | Site Name for Google Search

WordPress plugin Site Name for Google Search scored78%from 54 tests.

About plugin

  • Plugin page: site-name-for-goo...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.9.8
  • WordPress version: 6.3.1
  • First release: Apr 23, 2015
  • Latest release: Dec 12, 2018
  • Number of updates: 9
  • Update frequency: every 147.7 days
  • Top authors: Radices (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /914 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

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

Server-side resources used by Site Name for Google Search
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.39 ▼0.0821.17 ▼18.35
Dashboard /wp-admin3.31 ▼0.0348.94 ▼16.04
Posts /wp-admin/edit.php3.37 ▲0.0146.34 ▼9.40
Add New Post /wp-admin/post-new.php5.89 ▲0.0182.35 ▼16.60
Media Library /wp-admin/upload.php3.24 ▲0.0137.65 ▲2.07
Site Name for Google Search /wp-admin/options-general.php?page=site_name_for_google_search3.1832.76

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Site Name for Google Search
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,796 ▲3514.24 ▼0.111.72 ▲0.0839.01 ▼3.81
Dashboard /wp-admin2,199 ▲195.62 ▲0.0988.85 ▼3.0743.99 ▼1.33
Posts /wp-admin/edit.php2,104 ▲12.02 ▲0.0535.85 ▼6.5136.16 ▼2.18
Add New Post /wp-admin/post-new.php1,531 ▲523.17 ▼0.33660.99 ▲18.9874.04 ▲23.06
Media Library /wp-admin/upload.php1,404 ▲14.19 ▼0.02106.00 ▲0.9044.54 ▲1.26
Site Name for Google Search /wp-admin/options-general.php?page=site_name_for_google_search8351.9925.4727.59

Uninstaller [IO: ▲0.00MB] [DB: ▲0.07MB] 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
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These server-side errors were triggered
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=site_name_for_google_search
    • > Notice in wp-content/plugins/site-name-for-google-search/sngs.php+104
    Trying to access array offset on value of type bool

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/site-name-for-google-search/sngs.php:32

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

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
No tags were found

site-name-for-google-search/sngs.php 92% from 13 tests

"Site Name for Google Search" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("site-name-for-google-search.php" instead of "sngs.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected90 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1552590

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.00
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%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
PNG images were not found in this plugin