89% tcbd-tooltip

Code Review | TCBD Tooltip

WordPress plugin TCBD Tooltip scored89%from 54 tests.

About plugin

  • Plugin page: tcbd-tooltip
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-4.2.2
  • WordPress version: 6.3.1
  • First release: Jul 16, 2015
  • Latest release: Jul 16, 2015
  • Number of updates: 7
  • Update frequency: N/A
  • Top authors: tcoder (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /1,151 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼8.66ms] Passed 4 tests

Server-side resources used by TCBD Tooltip
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.75 ▲0.0244.79 ▼3.35
Dashboard /wp-admin3.58 ▲0.0248.43 ▼7.07
Posts /wp-admin/edit.php3.69 ▲0.0149.63 ▼6.79
Add New Post /wp-admin/post-new.php6.16 ▲0.0195.77 ▼17.42
Media Library /wp-admin/upload.php3.50 ▲0.0139.60 ▼1.15

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for TCBD Tooltip
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,899 ▲13813.86 ▼0.898.83 ▲6.8844.78 ▲6.24
Dashboard /wp-admin2,198 ▲185.61 ▲0.0087.50 ▼6.1141.68 ▼2.00
Posts /wp-admin/edit.php2,100 ▼02.03 ▲0.0239.31 ▼2.8034.35 ▼0.22
Add New Post /wp-admin/post-new.php1,554 ▲1118.15 ▼0.23616.29 ▼26.6260.46 ▲1.25
Media Library /wp-admin/upload.php1,397 ▼34.21 ▼0.02104.36 ▼1.1644.33 ▲0.93

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP Passed 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need your attention:
  • Screenshots: These screenshots require images: #1 (TCBD Tooltip Button), #2 (TCBD Tooltip Link), #3 (TCBD Tooltip Text), #4 (TCBD Tooltip Preview)
The official readme.txt is a good inspiration

tcbd-tooltip/plugin-hook.php 92% from 13 tests

The entry point to "TCBD Tooltip" version 1.0 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("tcbd-tooltip.php" instead of "plugin-hook.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected136 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript30089
PHP1122146
CSS1001

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.18
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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 PNG files occupy 0.08MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-4.png33.68KB14.49KB▼ 56.97%
js/icon.png3.09KB3.23KB0.00%
screenshot-1.png12.73KB5.40KB▼ 57.60%
screenshot-3.png14.46KB7.06KB▼ 51.19%
screenshot-2.png14.81KB7.27KB▼ 50.91%