84% home-schema

Code Review | Schema

WordPress plugin Schema scored84%from 54 tests.

About plugin

  • Plugin page: home-schema
  • Plugin version: 2.0
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.6
  • WordPress version: 6.3.1
  • First release: Feb 15, 2021
  • Latest release: Oct 14, 2021
  • Number of updates: 13
  • Update frequency: every 18.8 days
  • Top authors: manjeetkaur (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

10+ active /508 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.12MB] [CPU: ▼6.51ms] Passed 4 tests

An overview of server-side resources used by Schema
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.0938.54 ▲0.28
Dashboard /wp-admin3.45 ▲0.1043.31 ▼16.08
Posts /wp-admin/edit.php3.48 ▲0.1245.30 ▲1.78
Add New Post /wp-admin/post-new.php6.12 ▲0.2383.57 ▼10.87
Media Library /wp-admin/upload.php3.38 ▲0.1534.14 ▲0.62

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
widget_recent-posts
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for Schema
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,831 ▲8514.74 ▲0.361.67 ▲0.1139.83 ▼3.96
Dashboard /wp-admin2,206 ▲145.79 ▲0.8892.52 ▼15.5940.60 ▼3.64
Posts /wp-admin/edit.php2,089 ▼02.03 ▲0.0438.85 ▲4.5035.33 ▲3.66
Add New Post /wp-admin/post-new.php1,514 ▼1917.51 ▼5.64677.00 ▼23.8754.62 ▼3.38
Media Library /wp-admin/upload.php1,388 ▲34.19 ▲0.0196.84 ▼4.8841.06 ▼6.96

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 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
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/home-schema/Schema.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Tags: Too many tags (65 tag instead of maximum 10); only the first 5 tags are used in your directory listing
Please take inspiration from this readme.txt

home-schema/Schema.php 92% from 13 tests

The main file in "Schema" v. 2.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("home-schema.php" instead of "Schema.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected522 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP110442522

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.59
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%
Functions12
▷ Named functions12100.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
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
download.png1.81KB1.70KB▼ 6.25%