89% attributes-table

Code Review | Attributes Table

WordPress plugin Attributes Table scored89%from 54 tests.

About plugin

  • Plugin page: attributes-table
  • Plugin version: 1.2.13
  • PHP version: 7.4.16
  • WordPress compatibility: 3.7-6.3
  • WordPress version: 6.3.1
  • First release: Oct 13, 2015
  • Latest release: Aug 2, 2023
  • Number of updates: 51
  • Update frequency: every 55.9 days
  • Top authors: impleCode (100%)

Code review

54 tests

User reviews

1 review

Install metrics

400+ active /14,080 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.49MB] [CPU: ▼7.12ms] Passed 4 tests

Analyzing server-side resources used by Attributes Table
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /4.00 ▲0.5346.01 ▼12.09
Dashboard /wp-admin3.83 ▲0.5350.29 ▼5.09
Posts /wp-admin/edit.php3.89 ▲0.5252.48 ▲1.21
Add New Post /wp-admin/post-new.php6.35 ▲0.4690.78 ▼12.52
Media Library /wp-admin/upload.php3.70 ▲0.4650.04 ▲14.61
Attributes Table /wp-admin/options-general.php?page=ic_attributes3.6637.68

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 28 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

Attributes Table: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲2214.34 ▲0.181.82 ▼0.3139.47 ▼2.85
Dashboard /wp-admin2,199 ▲195.56 ▼0.0982.36 ▼17.1538.58 ▼4.69
Posts /wp-admin/edit.php2,104 ▲71.98 ▲0.0336.81 ▲2.7233.39 ▼2.00
Add New Post /wp-admin/post-new.php1,529 ▲323.83 ▲0.20682.34 ▲53.6552.41 ▲4.49
Media Library /wp-admin/upload.php1,404 ▲74.20 ▲0.06105.64 ▲5.0946.87 ▼0.02
Attributes Table /wp-admin/options-general.php?page=ic_attributes8341.9927.0930.04

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
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded

Smoke tests Passed 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)
Even though no errors were found, this is by no means an exhaustive test

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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need to be fixed:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === attributes-table === )
  • Screenshots: Add images for these screenshots: #1 (Attributes table on add/edit screen.), #2 (Attributes table on front-end.), #3 (Attributes table settings.)
You can look at the official readme.txt

attributes-table/attributes-table.php 92% from 13 tests

The principal PHP file in "Attributes Table" v. 1.2.13 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Domain Path: The domain path is invalid: folder "/lang/" does not exist

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected2,620 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
PHP214126492,620

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.54
Average class complexity46.00
▷ Minimum class complexity41.00
▷ Maximum class complexity51.00
Average method complexity4.10
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods29
▷ Static methods13.45%
▷ Public methods29100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions126
▷ Named functions126100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.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
1 PNG file occupies 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
img/implecode.png11.70KB5.04KB▼ 56.91%