94% add-post-link

Code Review | Add Post Link

WordPress plugin Add Post Link scored 94% from 54 tests.

About plugin

  • Plugin page: add-post-link
  • Plugin version: 1.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3-4.5
  • WordPress version: 5.9.2
  • First release: Jun 21, 2016
  • Latest release: Jun 21, 2016
  • Number of updates: 3
  • Update frequency: N/A
  • Top authors: beek.yoshida (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 621 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▼0.01MB] [CPU: ▼305.92ms] Passed 4 tests

A check of server-side resources used by Add Post Link
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0148.98 ▼6.62
Dashboard /wp-admin3.42 ▲0.0131.58 ▼1.97
Posts /wp-admin/edit.php3.65 ▲0.0135.10 ▼2.77
Add New Post /wp-admin/post-new.php6.89 ▼0.0894.39 ▼1,212.32
Media Library /wp-admin/upload.php3.30 ▲0.0123.78 ▼0.43
Add Post Link /wp-admin/plugins.php?page=add-post-link/add-post-link.php3.2721.53

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 5 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Add Post Link: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,808 ▲6215.98 ▲0.386.56 ▲0.212.93 ▲0.72
Dashboard /wp-admin2,899 ▲386.16 ▼0.13114.28 ▼18.35153.71 ▼11.65
Posts /wp-admin/edit.php2,698 ▲73.24 ▲0.0262.20 ▲0.44136.86 ▼5.64
Add New Post /wp-admin/post-new.php1,757 ▼2421.08 ▼2.00462.66 ▼57.77172.62 ▲6.68
Media Library /wp-admin/upload.php1,705 ▲105.44 ▼0.10142.93 ▼4.71184.54 ▼12.24
Add Post Link /wp-admin/plugins.php?page=add-post-link/add-post-link.php1,2012.5051.48121.62

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Uninstall script ran successfully

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)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% 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 fix the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/add-post-link/add-post-link.php:30

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side


Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
No plugin tags provided

add-post-link/add-post-link.php Passed 13 tests

The main file in "Add Post Link" v. 1.2.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
39 characters long description:
Add shortcode any post link to content.

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
Good job! No executable or dangerous file extensions detected421 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for 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.28
Average class complexity43.00
▷ Minimum class complexity43.00
▷ Maximum class complexity43.00
Average method complexity3.33
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods18100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions4100.00%
▷ Anonymous functions00.00%
▷ Global constants00.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
There are no PNG files in this plugin