84% block-feed-and-comments-via-robots-txt

Code Review | Block Feed and Comments via robots.txt

WordPress plugin Block Feed and Comments via robots.txt scored 84% from 54 tests.

About plugin

  • Plugin page: block-feed-and-co...
  • Plugin version: 1.2.0
  • PHP compatiblity: 7.1+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.1-6.3
  • WordPress version: 6.3.1
  • First release: Aug 29, 2020
  • Latest release: Sep 23, 2023
  • Number of updates: 21
  • Update frequency: every 53.3 days
  • Top authors: apasionados (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active / 1,205 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

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

An overview of server-side resources used by Block Feed and Comments via robots.txt
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0240.23 ▼3.24
Dashboard /wp-admin3.32 ▲0.0245.16 ▲0.06
Posts /wp-admin/edit.php3.37 ▲0.0248.16 ▼1.10
Add New Post /wp-admin/post-new.php5.90 ▲0.0296.13 ▼2.81
Media Library /wp-admin/upload.php3.24 ▲0.0236.55 ▲0.53

Server storage [IO: ▲0.02MB] [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
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Block Feed and Comments via robots.txt
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.36 ▼1.224.63 ▲2.7539.94 ▼4.03
Dashboard /wp-admin2,206 ▲515.91 ▲0.22101.20 ▲1.1040.90 ▼5.05
Posts /wp-admin/edit.php2,089 ▼32.03 ▼0.0338.96 ▲0.9834.21 ▲2.08
Add New Post /wp-admin/post-new.php1,533 ▲1423.23 ▲0.10603.39 ▲1.0850.59 ▼7.63
Media Library /wp-admin/upload.php1,388 ▼04.21 ▲0.0694.34 ▼10.1139.87 ▼4.21

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
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

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× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/block-feed-and-comments-via-robots-txt/block-feeds-comments-robots-txt.php:26

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)
There were no browser issues found

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
6 plugin tags: bot, robot, robotstxt, robots, seo...

block-feed-and-comments-via-robots-txt/block-feeds-comments-robots-txt.php 92% from 13 tests

This is the main PHP file of "Block Feed and Comments via robots.txt" version 1.2.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
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 ("block-feed-and-comments-via-robots-txt.php" instead of "block-feeds-comments-robots-txt.php")

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 detected86 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PO File16661
PHP152825

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
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%
Functions3
▷ Named functions3100.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
There were not PNG files found in your plugin