84% wp-contributions

Code Review | WP Contributions

WordPress plugin WP Contributions scored84%from 54 tests.

About plugin

  • Plugin page: wp-contributions
  • Plugin version: 1.2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8.0-6.0
  • WordPress version: 6.3.1
  • First release: May 11, 2015
  • Latest release: Feb 17, 2023
  • Number of updates: 26
  • Update frequency: every 109.3 days
  • Top authors: colorful tones (50%)tw2113 (38.46%)dustyf (19.23%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,073 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲0.24MB] [CPU: ▼2.55ms] Passed 4 tests

An overview of server-side resources used by WP Contributions
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.73 ▲0.2635.00 ▼5.94
Dashboard /wp-admin3.54 ▲0.2442.58 ▼8.46
Posts /wp-admin/edit.php3.65 ▲0.3042.76 ▲2.37
Add New Post /wp-admin/post-new.php6.12 ▲0.2489.90 ▲1.82
Media Library /wp-admin/upload.php3.46 ▲0.2336.55 ▲2.87

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 48 new files
Database: no new tables, 10 new options
New WordPress options
db_upgraded
widget_recent-posts
widget_wp-contributions-theme-widget
widget_recent-comments
widget_wp-contributions-core-widget
widget_theysaidso_widget
theysaidso_admin_options
widget_wp-contributions-plugin-widget
can_compress_scripts
widget_wp-contributions-codex-widget

Browser metrics Passed 4 tests

A check of browser resources used by WP Contributions
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,794 ▲3314.36 ▼0.181.50 ▼0.4638.30 ▼6.87
Dashboard /wp-admin2,195 ▲215.65 ▲0.1284.20 ▼11.7138.94 ▼1.84
Posts /wp-admin/edit.php2,103 ▲32.02 ▲0.0435.17 ▼1.1334.20 ▼5.14
Add New Post /wp-admin/post-new.php6,375 ▲4,84922.39 ▼0.73843.36 ▲176.1559.43 ▲5.51
Media Library /wp-admin/upload.php1,403 ▼04.21 ▼0.0195.66 ▼3.4542.96 ▼4.26

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: 10 options
    • widget_wp-contributions-theme-widget
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • widget_wp-contributions-core-widget
    • widget_wp-contributions-plugin-widget
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_wp-contributions-codex-widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

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
The following issues need your attention
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/wp-contributions/templates/wp-contributions-codex-widget-template.php
    • > /wp-content/plugins/wp-contributions/templates/wp-contributions-core-widget-template.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
6 plugin tags: codex, contributions, plugins, widget, core...

wp-contributions/wp-contributions.php 92% from 13 tests

Analyzing the main PHP file in "WP Contributions" version 1.2.1
Please take the time to fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 143 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin30,092 lines of code in 36 files:
LanguageFilesBlank linesComment linesLines of code
JSON40028,564
PHP163365831,121
JavaScript41634145
Sass7258138
CSS411173
Markdown133051

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity12.11
▷ Minimum class complexity5.00
▷ Maximum class complexity26.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes9
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes00.00%
Methods50
▷ Static methods612.00%
▷ Public methods50100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
5 compressed PNG files occupy 0.02MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/icon-256x256.png1.18KB1.21KB0.00%
assets/banner-772x250.png4.21KB4.08KB▼ 3.25%
assets/icon-128x128.png0.69KB0.74KB0.00%
assets/images/plugin-icon.png0.55KB0.63KB0.00%
assets/banner-1544x500.png9.65KB9.18KB▼ 4.92%