78% read-database

Code Review | Read Database

WordPress plugin Read Database scored78%from 54 tests.

About plugin

  • Plugin page: read-database
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-4.7
  • WordPress version: 6.3.1
  • First release: Sep 27, 2016
  • Latest release: Oct 17, 2016
  • Number of updates: 8
  • Update frequency: every 20.1 days
  • Top authors: naikrahulda (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,249 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.04MB] [CPU: ▼4.48ms] Passed 4 tests

Analyzing server-side resources used by Read Database
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0538.65 ▼12.62
Dashboard /wp-admin3.35 ▲0.0448.62 ▲0.01
Posts /wp-admin/edit.php3.40 ▲0.0449.14 ▼1.88
Add New Post /wp-admin/post-new.php5.93 ▲0.0487.13 ▼3.43
Media Library /wp-admin/upload.php3.27 ▲0.0437.54 ▲4.01
Read Database /wp-admin/admin.php?page=read_database3.2132.23
Settings /wp-admin/admin.php?page=read_database_settings3.2433.31

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Read Database
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,872 ▲12613.38 ▼0.852.78 ▲0.5740.88 ▼3.71
Dashboard /wp-admin2,246 ▲615.92 ▲1.02105.02 ▼3.9441.24 ▲4.16
Posts /wp-admin/edit.php2,129 ▲402.08 ▲0.0635.00 ▲1.2032.37 ▲0.78
Add New Post /wp-admin/post-new.php1,546 ▲3223.20 ▲5.69649.14 ▼21.3153.36 ▼0.62
Media Library /wp-admin/upload.php1,425 ▲374.27 ▲0.0895.73 ▼5.1941.36 ▼0.39
Read Database /wp-admin/admin.php?page=read_database8601.8723.8924.84
Settings /wp-admin/admin.php?page=read_database_settings8501.8724.6425.91

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/admin.php?page=read_database
    • > Notice in wp-content/plugins/read-database/classes.php+125
    Undefined variable: output

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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please fix the following browser errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=read_database_settings
    • > Network (severe)
    wp-content/plugins/read-database/js/script.min.js?ver=6.3.1 - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
8 plugin tags: data, database, read data in tables, read databse, read data...

read-database/index.php 92% from 13 tests

"Read Database" version 1.1'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: Name the main plugin file the same as the plugin slug ("read-database.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin180 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript445115173
CSS3003
PHP3003
XML1001

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity32.00
▷ Minimum class complexity32.00
▷ Maximum class complexity32.00
Average method complexity3.38
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods13
▷ Static methods00.00%
▷ Public methods1292.31%
▷ Protected methods00.00%
▷ Private methods17.69%
Functions2
▷ Named functions2100.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
No PNG images were found in this plugin