94% stacktack

Code Review | StackTack

WordPress plugin StackTack scored 94% from 54 tests.

About plugin

  • Plugin page: stacktack
  • Plugin version: 1.2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-3.4.2
  • WordPress version: 5.9.2
  • First release: Mar 19, 2012
  • Latest release: Dec 1, 2012
  • Number of updates: 11
  • Update frequency: every 23.4 days
  • Top authors: george_edison (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,295 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼324.56ms] Passed 4 tests

Server-side resources used by StackTack
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.0759.78 ▼10.50
Dashboard /wp-admin3.44 ▲0.0334.57 ▼0.38
Posts /wp-admin/edit.php3.67 ▲0.0341.21 ▲5.97
Add New Post /wp-admin/post-new.php6.91 ▼0.0796.52 ▼1,293.34
Media Library /wp-admin/upload.php3.32 ▲0.0236.21 ▲10.32
StackTack /wp-admin/options-general.php?page=stacktack-options3.3029.58

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 13 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for StackTack
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /4,040 ▲31816.22 ▲0.649.29 ▲2.842.87 ▼0.02
Dashboard /wp-admin3,020 ▲1676.16 ▲0.06121.38 ▼4.50181.41 ▼53.42
Posts /wp-admin/edit.php2,816 ▲1313.24 ▲0.0167.51 ▼8.18147.85 ▼8.72
Add New Post /wp-admin/post-new.php1,747 ▲8121.30 ▲0.45521.07 ▲71.06201.21 ▼0.40
Media Library /wp-admin/upload.php1,827 ▲1335.56 ▲0.01160.52 ▼20.24213.22 ▲1.92
StackTack /wp-admin/options-general.php?page=stacktack-options1,2462.4456.99123.64

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstall script ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for 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
Please fix the following
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/stacktack/stacktack.php:162
    • > PHP Fatal error
      Uncaught Error: Call to undefined function current_user_can() in wp-content/plugins/stacktack/stacktack_options.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found


Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that require attention:
  • Screenshots: These screenshots require images: #1 (StackTack icon in the editing toolbar.), #2 (An instance of StackTack in a post.)
The official readme.txt is a good inspiration

stacktack/stacktack.php Passed 13 tests

"StackTack" version 1.2.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
96 characters long description:
A WordPress plugin that makes it easy to embed questions from Stack Exchange sites in your blog.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Good job! No executable or dangerous file extensions detected346 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity8.00
▷ Minimum class complexity8.00
▷ Maximum class complexity8.00
Average method complexity1.78
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods9100.00%
▷ Public methods9100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions00.00%
▷ Anonymous functions00.00%
▷ Global constants00.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
4 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png3.72KB2.56KB▼ 31.12%
screenshot-2.png25.85KB13.46KB▼ 47.94%
img/icon.png1.38KB1.33KB▼ 3.12%
tinymce/button.png0.68KB0.61KB▼ 9.94%