10% wedgeprint

Code Review | WedgePrint

WordPress plugin WedgePrint scored10%from 54 tests.

About plugin

  • Plugin page: wedgeprint
  • Plugin version: 0.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2.1-3.3.1
  • WordPress version: 6.3.1
  • First release: Mar 16, 2012
  • Latest release: Mar 24, 2012
  • Number of updates: 7
  • Update frequency: every 1.1 days
  • Top authors: dweius (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /906 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Please fix the following installer errors
  • The plugin cannot be installed
    • > Deprecated in wp-includes/class-wp-hook.php+310
    Non-static method WedgePrintInit::on_activate() should not be called statically

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

Analyzing server-side resources used by WedgePrint
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0537.98 ▲1.55
Dashboard /wp-admin3.36 ▲0.0148.09 ▼15.03
Posts /wp-admin/edit.php3.41 ▲0.0544.51 ▲0.67
Add New Post /wp-admin/post-new.php5.94 ▲0.0580.79 ▼5.63
Media Library /wp-admin/upload.php3.28 ▲0.0533.75 ▼0.03

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 9 new files
Database: 1 new table, 16 new options
New tables
wp_wedgeprint_wedges
New WordPress options
widget_theysaidso_widget
wedgeprint_interval
wedgeprint_closeid
theysaidso_admin_options
wedgeprint_cookie_name
can_compress_scripts
wedgeprint_time
wedgeprint_db_version
wedgeprint_version
wedgeprint_source
...

Browser metrics Passed 4 tests

WedgePrint: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲4714.53 ▼0.031.79 ▲0.2443.17 ▲1.60
Dashboard /wp-admin2,202 ▲225.56 ▼0.0995.08 ▲8.0641.98 ▼0.41
Posts /wp-admin/edit.php2,104 ▲42.03 ▲0.0833.27 ▼4.1135.67 ▲1.76
Add New Post /wp-admin/post-new.php1,531 ▲323.14 ▼0.09658.37 ▼17.1949.55 ▲0.12
Media Library /wp-admin/upload.php1,407 ▲74.17 ▼0.05110.32 ▲9.8547.36 ▼3.59
WedgePrint Manager /wp-admin/wedgeprint.php260.420.0912.68

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • This plugin cannot be uninstalled
    • > Deprecated in wp-includes/class-wp-hook.php+310
    Non-static method WedgePrintInit::on_deactivate() should not be called statically
  • Zombie WordPress options detected upon uninstall: 7 options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • wedgeprint_db_version
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 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
Please fix the following
  • 3× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/wedgeprint/common/wedgeprint_inner.php
    • > /wp-content/plugins/wedgeprint/wedgeprint_admin.php
    • > /wp-content/plugins/wedgeprint/wedgeprint.php

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please fix the following user-side errors
    • > GET request to /wp-admin/wedgeprint.php
    • > Network (severe)
    wp-admin/wedgeprint.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Screenshots: Screenshot #1 (Overview of the new 'WedgePrint Manager', `/tags/0.2.0/screenshot-1.png`) image not found
The official readme.txt might help

wedgeprint/wedgeprint.php Passed 13 tests

The main PHP file in "WedgePrint" ver. 0.2.0 adds more information about the plugin and also serves as the entry point for this plugin
137 characters long description:
WedgePrint plugin for WordPress is an easy way to show your readers short-time visual screenshots while loading your requested blog page.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin610 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP5134193563
HTML22047

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity23.00
▷ Minimum class complexity23.00
▷ Maximum class complexity23.00
Average method complexity4.67
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions6
▷ Named functions6100.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
1 PNG file occupies 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png51.71KB21.03KB▼ 59.33%