78% story-chief

Code Review | StoryChief

WordPress plugin StoryChief scored78%from 54 tests.

About plugin

  • Plugin page: story-chief
  • Plugin version: 1.0.37
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.0
  • WordPress version: 6.3.1
  • First release: Jan 27, 2017
  • Latest release: Feb 8, 2023
  • Number of updates: 93
  • Update frequency: every 23.7 days
  • Top authors: storychief (100%)

Code review

54 tests

User reviews

13 reviews

Install metrics

1,000+ active /45,679 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.30MB] [CPU: ▼0.37ms] Passed 4 tests

This is a short check of server-side resources used by StoryChief
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.72 ▲0.2648.42 ▲5.32
Dashboard /wp-admin3.67 ▲0.3254.42 ▼14.64
Posts /wp-admin/edit.php3.72 ▲0.3657.41 ▲7.39
Add New Post /wp-admin/post-new.php6.19 ▲0.30104.60 ▲2.46
Media Library /wp-admin/upload.php3.53 ▲0.3043.62 ▲5.38
StoryChief /wp-admin/options-general.php?page=storychief3.5648.35

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 24 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_recent-comments
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for StoryChief
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,795 ▲3414.72 ▲0.381.58 ▼0.5342.48 ▲0.70
Dashboard /wp-admin2,193 ▲135.61 ▼0.0792.66 ▼2.9541.97 ▲0.77
Posts /wp-admin/edit.php2,104 ▲42.03 ▲0.0941.56 ▲4.4835.82 ▼4.95
Add New Post /wp-admin/post-new.php1,540 ▲1418.40 ▼4.83636.96 ▼61.7766.85 ▼5.73
Media Library /wp-admin/upload.php1,407 ▲44.17 ▼0.02100.77 ▼0.5643.74 ▲0.23
StoryChief /wp-admin/options-general.php?page=storychief1,0562.0022.7328.79

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
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

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
Almost there! Just fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/story-chief/storychief.php
  • 17× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      require_once(): Failed opening required 'STORYCHIEF_DIR/includes/lib/wp-async-task/wp-async-task.php' (include_path='.:/usr/share/php') in wp-content/plugins/story-chief/includes/async-tasks.php on line 16
    • > PHP Warning
      require_once(STORYCHIEF_DIR/includes/lib/wp-async-task/wp-async-task.php): failed to open stream: No such file or directory in wp-content/plugins/story-chief/includes/async-tasks.php on line 16
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/story-chief/views/notice.php on line 15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Storychief\\Formatting\\add_action() in wp-content/plugins/story-chief/includes/formatting.php:12
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/story-chief/views/notice.php on line 36
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Storychief\\Webhook\\add_action() in wp-content/plugins/story-chief/includes/webhook.php:18
    • > PHP Warning
      Use of undefined constant STORYCHIEF_DIR - assumed 'STORYCHIEF_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/story-chief/includes/async-tasks.php on line 16
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/story-chief/views/notice.php on line 22
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/story-chief/views/notice.php on line 42
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Async_Task' not found in wp-content/plugins/story-chief/includes/async-tasks/class-sideloadimages.php:15

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
7 plugin tags: schedule posts to linkedin, content marketing calendar, schedule facebook posts, content marketing, schedule to twitter...

story-chief/storychief.php 85% from 13 tests

The principal PHP file in "StoryChief" v. 1.0.37 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: The principal plugin file should be the same as the plugin slug ("story-chief.php" instead of "storychief.php")

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
No dangerous file extensions were detected1,588 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PHP162905071,428
Markdown2420103
JSON10037
CSS32020

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.46
Average class complexity18.50
▷ Minimum class complexity3.00
▷ Maximum class complexity38.00
Average method complexity3.09
▷ Minimum method complexity1.00
▷ Maximum method complexity20.00
Code structure
Namespaces8
Interfaces0
Traits0
Classes4
▷ Abstract classes125.00%
▷ Concrete classes375.00%
▷ Final classes00.00%
Methods35
▷ Static methods1954.29%
▷ Public methods2880.00%
▷ Protected methods720.00%
▷ Private methods00.00%
Functions52
▷ Named functions5198.08%
▷ Anonymous functions11.92%
Constants7
▷ Global constants342.86%
▷ Class constants457.14%
▷ Public constants4100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There were not PNG files found in your plugin