84% schema-scalpel

Code Review | Schema Scalpel

WordPress plugin Schema Scalpel scored84%from 54 tests.

About plugin

  • Plugin page: schema-scalpel
  • Plugin version: 1.3
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.3.2
  • WordPress version: 6.3.1
  • First release: Apr 21, 2022
  • Latest release: Oct 23, 2023
  • Number of updates: 101
  • Update frequency: every 5.5 days
  • Top authors: kevingillispie (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,086 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.14MB] [CPU: ▼4.18ms] Passed 4 tests

Server-side resources used by Schema Scalpel
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1540.75 ▲1.67
Dashboard /wp-admin3.46 ▲0.1148.14 ▼13.77
Posts /wp-admin/edit.php3.57 ▲0.2149.95 ▼0.93
Add New Post /wp-admin/post-new.php6.04 ▲0.1599.10 ▼3.20
Media Library /wp-admin/upload.php3.38 ▲0.1538.12 ▲1.20
Export /wp-admin/admin.php?page=scsc_export3.4937.32
Add New / Edit /wp-admin/admin.php?page=scsc3.5544.58
Settings /wp-admin/admin.php?page=scsc_settings3.4837.50

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Schema Scalpel
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,844 ▲8314.43 ▼0.191.52 ▼0.1640.16 ▼0.37
Dashboard /wp-admin2,246 ▲695.52 ▼0.0581.59 ▼1.3856.71 ▲12.81
Posts /wp-admin/edit.php2,154 ▲572.00 ▼0.0138.76 ▲2.8434.29 ▼1.38
Add New Post /wp-admin/post-new.php1,582 ▲5623.01 ▼0.19705.17 ▲38.3254.20 ▼12.08
Media Library /wp-admin/upload.php1,454 ▲514.11 ▼0.1091.50 ▼6.3980.54 ▲36.23
Export /wp-admin/admin.php?page=scsc_export9302.3829.9262.87
Add New / Edit /wp-admin/admin.php?page=scsc12,0603.8583.0227.37
Settings /wp-admin/admin.php?page=scsc_settings2,1582.3336.6569.76

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

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

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The SRP test was a success

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Please fix the following browser errors
    • > GET request to /wp-admin/admin.php?page=scsc
    • > Javascript (severe) in unknown
    /wp-admin/admin.php?page=scsc 475:17 Uncaught TypeError: Cannot read properties of undefined (reading 'classList')

Optimizations

Plugin configuration Passed 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: schema, search engine, structured data, microdata, seo...

schema-scalpel/schema-scalpel.php Passed 13 tests

The main PHP script in "Schema Scalpel" version 1.3 is automatically included on every request by WordPress
68 characters long description:
A simple plugin to customize your site's schema on a per-page basis.

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
Everything looks great! No dangerous files found in this plugin2,325 lines of code in 36 files:
LanguageFilesBlank linesComment linesLines of code
PHP213053091,565
JavaScript54825407
CSS44519283
SVG60070

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity7.43
▷ Minimum class complexity1.00
▷ Maximum class complexity26.00
Average method complexity2.45
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods33
▷ Static methods515.15%
▷ Public methods2575.76%
▷ Protected methods00.00%
▷ Private methods824.24%
Functions6
▷ Named functions233.33%
▷ Anonymous functions466.67%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin