84% capital-s-dangit

Code Review | Capital S, Dangit!

WordPress plugin Capital S, Dangit! scored84%from 54 tests.

About plugin

  • Plugin page: capital-s-dangit
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.1
  • WordPress version: 6.3.1
  • First release: Nov 9, 2018
  • Latest release: Feb 25, 2019
  • Number of updates: 5
  • Update frequency: every 21.8 days
  • Top authors: dimadin (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /836 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

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

An overview of server-side resources used by Capital S, Dangit!
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0137.28 ▼5.42
Dashboard /wp-admin3.31 ▲0.0146.79 ▼2.11
Posts /wp-admin/edit.php3.36 ▲0.0048.29 ▲1.90
Add New Post /wp-admin/post-new.php5.89 ▲0.0083.30 ▼6.36
Media Library /wp-admin/upload.php3.23 ▲0.0038.99 ▲4.81

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Capital S, Dangit!
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.27 ▼1.091.70 ▼0.2343.20 ▼7.50
Dashboard /wp-admin2,209 ▲575.88 ▲0.19103.60 ▼9.7739.99 ▼3.75
Posts /wp-admin/edit.php2,092 ▲32.02 ▼0.0441.14 ▲1.3233.68 ▼3.10
Add New Post /wp-admin/post-new.php1,534 ▲123.40 ▲0.54668.82 ▲43.8664.52 ▲7.23
Media Library /wp-admin/upload.php1,385 ▼34.20 ▼0.0393.34 ▼5.1242.52 ▼2.54

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 75% from 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)
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 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
Please fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/capital-s-dangit/capital-s-dangit.php:47

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
1 plugin tags: javascript

capital-s-dangit/capital-s-dangit.php 92% from 13 tests

The main PHP file in "Capital S, Dangit!" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
You should first fix the following items:
  • Domain Path: The domain path points to a folder that does not exist ("/languages")

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
There were no executable files found in this plugin62 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
XML15535
PHP173427

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ 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
No PNG images were found in this plugin