78% wp-datadisplay

Code Review | WP DataDisplay

WordPress plugin WP DataDisplay scored78%from 54 tests.

About plugin

  • Plugin page: wp-datadisplay
  • Plugin version: 0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8.1-4.1.1
  • WordPress version: 6.3.1
  • First release: Mar 26, 2015
  • Latest release: Mar 26, 2015
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: alantygel (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /592 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.03MB] [CPU: ▼6.86ms] Passed 4 tests

Analyzing server-side resources used by WP DataDisplay
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0341.59 ▼0.42
Dashboard /wp-admin3.33 ▲0.0345.21 ▼5.13
Posts /wp-admin/edit.php3.38 ▲0.0346.50 ▼4.80
Add New Post /wp-admin/post-new.php5.91 ▲0.0382.17 ▼15.70
Media Library /wp-admin/upload.php3.25 ▲0.0335.42 ▼1.81
WPDataDisplay /wp-admin/options-general.php?page=wpdatadisplay3.2029.75
Data Display /wp-admin/edit.php?post_type=wpdatadisplay3.3035.15
Add New /wp-admin/post-new.php?post_type=wpdatadisplay3.4050.29

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for WP DataDisplay
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,834 ▲7713.37 ▼1.001.80 ▼0.4643.74 ▼7.48
Dashboard /wp-admin2,231 ▲435.84 ▲0.0497.50 ▼10.0038.27 ▼4.13
Posts /wp-admin/edit.php2,120 ▲312.03 ▲0.0434.68 ▼5.6235.39 ▼0.31
Add New Post /wp-admin/post-new.php1,559 ▲2622.96 ▼0.26662.39 ▼3.0459.16 ▲5.70
Media Library /wp-admin/upload.php1,422 ▲374.27 ▲0.1098.45 ▼13.9442.83 ▼4.32
WPDataDisplay /wp-admin/options-general.php?page=wpdatadisplay8662.0222.0023.68
Data Display /wp-admin/edit.php?post_type=wpdatadisplay1,1351.9330.1031.09
Add New /wp-admin/post-new.php?post_type=wpdatadisplay2,8177.71179.2275.22

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
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These errors were triggered by the plugin
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=wpdatadisplay
    • > Notice in wp-content/plugins/wp-datadisplay/wpdatadisplay.php+53
    Trying to access array offset on value of type bool

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-datadisplay/wpdatadisplay.php:32

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were 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
2 plugin tags: custom database, data

wp-datadisplay/wpdatadisplay.php 92% from 13 tests

The principal PHP file in "WP DataDisplay" v. 0.0 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("wp-datadisplay.php" instead of "wpdatadisplay.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
Success! There were no dangerous files found in this plugin245 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP26245231
CSS12014

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.16
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%
Functions15
▷ Named functions15100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.08MB with 0.06MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
datadisplay settings screen.png85.51KB28.65KB▼ 66.49%