84% wordpress-archive-chart

Code Review | Wordpress Archive Chart

WordPress plugin Wordpress Archive Chart scored84%from 54 tests.

About plugin

  • Plugin page: wordpress-archive...
  • Plugin version: 0.9.5
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.9
  • WordPress version: 6.3.1
  • First release: Oct 2, 2010
  • Latest release: Apr 18, 2014
  • Number of updates: 13
  • Update frequency: every 99.5 days
  • Top authors: campino2k (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,413 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.01MB] [CPU: ▼1.38ms] Passed 4 tests

Analyzing server-side resources used by Wordpress Archive Chart
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0239.16 ▲0.72
Dashboard /wp-admin3.32 ▲0.0243.53 ▼2.22
Posts /wp-admin/edit.php3.37 ▲0.0143.98 ▼2.89
Add New Post /wp-admin/post-new.php5.90 ▲0.0193.61 ▼1.14
Media Library /wp-admin/upload.php3.24 ▲0.0137.47 ▲2.05

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

Wordpress Archive Chart: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲4313.57 ▼1.091.73 ▼0.4241.72 ▲0.77
Dashboard /wp-admin2,206 ▲184.88 ▼1.01111.75 ▲12.5340.20 ▼2.27
Posts /wp-admin/edit.php2,089 ▼02.00 ▼0.0439.30 ▼2.2237.46 ▲0.91
Add New Post /wp-admin/post-new.php1,533 ▼923.35 ▲5.00610.17 ▼39.9948.24 ▼10.28
Media Library /wp-admin/upload.php1,391 ▲34.19 ▼0.0197.77 ▼2.3441.11 ▼1.67

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
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Almost there! Just fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/wordpress-archive-chart/index.php:103

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: Add an image for screenshot #1 (Display in the blog)
The official readme.txt might help

wordpress-archive-chart/index.php 92% from 13 tests

"Wordpress Archive Chart" version 0.9.5's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("wordpress-archive-chart.php" instead of "index.php")

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
Good job! No executable or dangerous file extensions detected57 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1153357

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.09
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%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png23.20KB8.52KB▼ 63.27%