84% author-posts-shortcode

Code Review | Author Posts Shortcode

WordPress plugin Author Posts Shortcode scored84%from 54 tests.

About plugin

  • Plugin page: author-posts-shor...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.8.2
  • WordPress version: 6.3.1
  • First release: Apr 10, 2014
  • Latest release: Apr 11, 2014
  • Number of updates: 12
  • Update frequency: every 0.1 days
  • Top authors: meathor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,031 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
Installer ran successfully

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

This is a short check of server-side resources used by Author Posts Shortcode
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0137.83 ▲0.30
Dashboard /wp-admin3.32 ▼0.0344.85 ▼12.28
Posts /wp-admin/edit.php3.37 ▲0.0144.43 ▼7.69
Add New Post /wp-admin/post-new.php5.90 ▲0.0189.10 ▼13.89
Media Library /wp-admin/upload.php3.24 ▲0.0133.14 ▼1.07

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Author Posts Shortcode
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.23 ▼1.121.68 ▼0.1544.17 ▲6.10
Dashboard /wp-admin2,206 ▲185.85 ▲0.96100.80 ▼3.2942.42 ▲2.52
Posts /wp-admin/edit.php2,092 ▼02.04 ▼0.0138.45 ▼3.4129.20 ▼5.69
Add New Post /wp-admin/post-new.php1,537 ▲1318.31 ▼4.91617.30 ▼68.2651.98 ▼5.17
Media Library /wp-admin/upload.php1,388 ▼04.22 ▲0.0498.33 ▼3.9849.13 ▲0.47

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
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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 take a closer look at the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/author-posts-shortcode/gomorrah-author-posts.php:82

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Plugin Name: You should set the name of your plugin on the first line ( === author-posts-shortcode === )
The official readme.txt might help

author-posts-shortcode/gomorrah-author-posts.php 92% from 13 tests

This is the main PHP file of "Author Posts Shortcode" version 1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("author-posts-shortcode.php" instead of "gomorrah-author-posts.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin64 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP111864

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.76
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%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
No PNG images were found in this plugin