90% discourage-search-engines-dashboard-notification

Code Review | Discourage Search Engines - Dashboard notification

WordPress plugin Discourage Search Engines - Dashboard notification scored90%from 54 tests.

About plugin

  • Plugin page: discourage-search...
  • Plugin version: 1.6
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.3
  • WordPress version: 6.3.1
  • First release: Mar 9, 2018
  • Latest release: Aug 18, 2023
  • Number of updates: 47
  • Update frequency: every 42.5 days
  • Top authors: FlintStoned- (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

200+ active /3,163 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼8.48ms] Passed 4 tests

A check of server-side resources used by Discourage Search Engines - Dashboard notification
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0240.63 ▼5.58
Dashboard /wp-admin3.32 ▼0.0252.27 ▼13.11
Posts /wp-admin/edit.php3.38 ▲0.0248.07 ▼1.13
Add New Post /wp-admin/post-new.php5.91 ▲0.0286.38 ▼14.08
Media Library /wp-admin/upload.php3.25 ▲0.0237.51 ▲1.09

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
widget_recent-comments
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Discourage Search Engines - Dashboard notification
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,797 ▲3614.72 ▲0.371.88 ▲0.2346.02 ▲6.54
Dashboard /wp-admin2,200 ▲205.56 ▼0.0189.39 ▼0.8340.75 ▲2.57
Posts /wp-admin/edit.php2,108 ▲81.98 ▲0.0236.29 ▼1.4234.94 ▼1.97
Add New Post /wp-admin/post-new.php1,603 ▲7722.39 ▲1.46664.65 ▼5.8930.87 ▼22.25
Media Library /wp-admin/upload.php1,411 ▲114.27 ▲0.1197.92 ▼22.9842.64 ▼8.65

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
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
6 plugin tags: search engine discourage, seo, dashboard notification, website index, development...

discourage-search-engines-dashboard-notification/ddw_discourage_search_engine_dashboard_notification.php 92% from 13 tests

The main PHP file in "Discourage Search Engines - Dashboard notification" ver. 1.6 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("discourage-search-engines-dashboard-notification.php" instead of "ddw_discourage_search_engine_dashboard_notification.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 plugin80 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP1101562
PO File11118

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.21
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%
Functions4
▷ Named functions4100.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
There are no PNG files in this plugin