10% archive-post-tabs

Code Review | Archive Post Tabs

WordPress plugin Archive Post Tabs scored10%from 54 tests.

About plugin

  • Plugin page: archive-post-tabs
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.9
  • WordPress version: 6.3.1
  • First release: Aug 16, 2016
  • Latest release: Jan 20, 2018
  • Number of updates: 11
  • Update frequency: every 47.7 days
  • Top authors: ikhodal (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,294 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
These installer errors require your attention
  • This plugin did not install gracefully
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in archivesPostTabWidget is deprecated since version 4.3.0! Use __construct() instead.

Server metrics [RAM: ▼1.97MB] [CPU: ▼52.35ms] Passed 4 tests

Analyzing server-side resources used by Archive Post Tabs
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.445.37 ▼34.10
Dashboard /wp-admin2.05 ▼1.307.34 ▼48.25
Posts /wp-admin/edit.php2.05 ▼1.316.78 ▼39.70
Add New Post /wp-admin/post-new.php2.05 ▼3.846.04 ▼87.36
Media Library /wp-admin/upload.php2.05 ▼1.185.81 ▼27.26
Archive Posts Tab /wp-admin/options-general.php?page=archivesposttab_settings2.056.31

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 26 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
db_upgraded
widget_archivesposttabadmin
widget_recent-posts
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Archive Post Tabs
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,904 ▲15813.62 ▼0.788.13 ▲6.2442.70 ▼0.59
Dashboard /wp-admin2,217 ▲294.90 ▲0.05107.71 ▼4.3739.37 ▼0.31
Posts /wp-admin/edit.php2,100 ▲142.04 ▼0.1337.03 ▲0.7035.00 ▲5.13
Add New Post /wp-admin/post-new.php1,524 ▼923.08 ▼0.04641.40 ▼43.5482.73 ▲26.52
Media Library /wp-admin/upload.php1,399 ▲144.25 ▲0.08103.35 ▲0.2642.42 ▼1.71
Archive Posts Tab /wp-admin/options-general.php?page=archivesposttab_settings8761.9928.5025.41

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Uninstall procedure validation failed for this plugin
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in archivesPostTabWidget is deprecated since version 4.3.0! Use __construct() instead.
  • Zombie WordPress options detected upon uninstall: 7 options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_archivesposttabadmin

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These server-side errors were triggered
    • > GET request to /wp-admin/options-general.php?page=archivesposttab_settings
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in archivesPostTabWidget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=archivesposttab_settings
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in archivesPostTabWidget_Admin is deprecated since version 4.3.0! Use __construct() instead.

SRP Passed 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% 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
Please fix the following attributes:
  • Tags: Please reduce the number of tags, currently 27 tag instead of maximum 10
  • Screenshots: These screenshots have no corresponding images in /assets: #20 (admin-shortcode-list.png), #21 (admin-add-shortcode.png), #22 (admin-add-widget.png)
You can look at the official readme.txt

archive-post-tabs/plugin.php 92% from 13 tests

The main file in "Archive Post Tabs" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("archive-post-tabs.php" instead of "plugin.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 detected1,674 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP112904201,163
JavaScript2390236
PO File1720162
CSS286113

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity17.25
▷ Minimum class complexity4.00
▷ Maximum class complexity31.00
Average method complexity3.24
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes125.00%
▷ Concrete classes375.00%
▷ Final classes00.00%
Methods29
▷ Static methods00.00%
▷ Public methods2896.55%
▷ Protected methods00.00%
▷ Private methods13.45%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants16
▷ Global constants16100.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
7 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/view-more.png0.36KB0.33KB▼ 7.14%
assets/images/searchicon.png0.80KB0.82KB0.00%
assets/images/view.png2.09KB1.45KB▼ 30.97%
assets/images/no-img.png3.66KB0.88KB▼ 76.05%
assets/images/right-icon.png0.36KB0.44KB0.00%