10% steem-wp

Code Review | Steem WP

WordPress plugin Steem WP scored10%from 54 tests.

About plugin

  • Plugin page: steem-wp
  • Plugin version: 0.0.5
  • PHP compatiblity: 5.6.20+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2.4-5.2.4
  • WordPress version: 6.3.1
  • First release: Nov 23, 2019
  • Latest release: Nov 23, 2019
  • Number of updates: 22
  • Update frequency: every 0.1 days
  • Top authors: steemwpcom (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /447 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
You still need to fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Notice in wp-content/plugins/steem-wp/src/constants.php+12
    Trying to access array offset on value of type bool

Server metrics [RAM: ▲0.05MB] [CPU: ▲0.50ms] Passed 4 tests

Server-side resources used by Steem WP
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0442.82 ▲1.77
Dashboard /wp-admin3.36 ▲0.0649.18 ▲0.33
Posts /wp-admin/edit.php3.41 ▲0.0549.94 ▲2.50
Add New Post /wp-admin/post-new.php5.93 ▲0.05100.55 ▲4.31
Media Library /wp-admin/upload.php3.28 ▲0.0544.30 ▼2.58

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 53 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
steemwp_auth_group
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Steem WP: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,843 ▲7213.22 ▼1.571.67 ▼1.0247.41 ▲4.24
Dashboard /wp-admin2,252 ▲644.88 ▼0.99107.28 ▼10.6139.90 ▼4.00
Posts /wp-admin/edit.php2,135 ▲462.01 ▲0.0143.59 ▲6.7735.91 ▲2.45
Add New Post /wp-admin/post-new.php1,549 ▼11923.16 ▲0.62663.18 ▼9.7950.76 ▼14.63
Media Library /wp-admin/upload.php1,431 ▲464.23 ▲0.11112.31 ▲5.5348.46 ▲2.57

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 50% 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)
Good news, no errors were detected

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/steem-wp/src/ui/admin/php/partials/footer.php
  • 23× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/steem-wp/src/ui/admin/php/auth.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/steem-wp/src/ui/admin/php/statistics.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/steem-wp/src/ui/admin/php/settings.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/steem-wp/src/hooks/lifecycle/activate.php:29
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/steem-wp/src/ui/admin/php/wizard.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/steem-wp/src/ui/admin/php/coming.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/steem-wp/src/ui/admin/php/support.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_uninstall_hook() in wp-content/plugins/steem-wp/src/hooks/lifecycle/uninstall.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/steem-wp/src/hooks/lifecycle/activate.php:29
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/steem-wp/src/lib/steemconnect/modules/login.php:49

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: blockchain, steemwp, steem

steem-wp/index.php 85% from 13 tests

The primary PHP file in "Steem WP" version 0.0.5 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("steem-wp.php" instead of "index.php")
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Good job! No executable or dangerous file extensions detected2,680 lines of code in 51 files:
LanguageFilesBlank linesComment linesLines of code
CSS42532791,242
JavaScript1017246695
PHP2825529563
JSON900180

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants31
▷ Global constants31100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin