78% wm-child-post

Code Review | WP Child Post

WordPress plugin WP Child Post scored78%from 54 tests.

About plugin

  • Plugin page: wm-child-post
  • Plugin version: 1.01
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-3.5.1
  • WordPress version: 6.3.1
  • First release: Jun 7, 2013
  • Latest release: Jun 18, 2013
  • Number of updates: 13
  • Update frequency: every 0.9 days
  • Top authors: repon.wp (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /2,308 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.07MB] [CPU: ▼1.49ms] Passed 4 tests

A check of server-side resources used by WP Child Post
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0739.61 ▼1.15
Dashboard /wp-admin3.38 ▲0.0852.59 ▲2.74
Posts /wp-admin/edit.php3.43 ▲0.0752.76 ▲5.04
Add New Post /wp-admin/post-new.php5.98 ▲0.1097.89 ▼6.35
Media Library /wp-admin/upload.php3.30 ▲0.0835.74 ▼1.21
All Child Post /wp-admin/edit.php?post_type=child-post3.3544.04
Groups /wp-admin/edit-tags.php?taxonomy=child-group&post_type=child-post3.3037.65
New Child Post /wp-admin/post-new.php?post_type=child-post3.4252.10

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for WP Child Post
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,008 ▲24713.50 ▼1.078.10 ▲6.4941.57 ▼0.08
Dashboard /wp-admin2,316 ▲1365.59 ▼0.0696.39 ▲6.4882.94 ▲40.63
Posts /wp-admin/edit.php2,239 ▲1392.01 ▲0.0440.09 ▲5.8034.48 ▲1.39
Add New Post /wp-admin/post-new.php1,662 ▲12623.21 ▲5.13779.52 ▲151.6258.57 ▼1.34
Media Library /wp-admin/upload.php1,530 ▲1274.18 ▼0.0396.88 ▼7.0878.88 ▲35.13
All Child Post /wp-admin/edit.php?post_type=child-post1,2221.9143.5742.55
Groups /wp-admin/edit-tags.php?taxonomy=child-group&post_type=child-post1,3822.1527.9831.27
New Child Post /wp-admin/post-new.php?post_type=child-post2,4647.67171.92133.67

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
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments

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 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
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/wm-child-post/wm-child-post.php:11

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
These are user-side errors you should fix
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/edit-tags.php?taxonomy=child-group&post_type=child-post
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28609 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/wm-child-post/js/wm-child-post.js?ver=1.01:28:31)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:27292)" undefined
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/edit-tags.php?taxonomy=child-group&post_type=child-post
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28721 Uncaught TypeError: $(...).live is not a function
    • > GET request to /wp-admin/post-new.php?post_type=child-post
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1 1:28609 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/wm-child-post/js/wm-child-post.js?ver=1.01:28:31)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1:2:27292)" undefined
    • > GET request to /wp-admin/post-new.php?post_type=child-post
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1 1:28721 Uncaught TypeError: $(...).live is not a function

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
  • Donate link: Invalid URI ("")
  • Screenshots: Please add images for these screenshots: #1 (screenshot-1.jpg), #2 (screenshot-2.jpg), #3 (screenshot-3.jpg), #4 (screenshot-4.jpg), #5 (screenshot-5.jpg)
The official readme.txt might help

wm-child-post/wm-child-post.php 92% from 13 tests

This is the main PHP file of "WP Child Post" version 1.01, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 201 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected349 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP25968224
JavaScript3222675
CSS212150

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity3.00
▷ Minimum class complexity3.00
▷ Maximum class complexity3.00
Average method complexity1.50
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods4100.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
4 PNG files occupy 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/collapse.png2.78KB0.17KB▼ 94.05%
js/icon.png3.92KB1.49KB▼ 61.92%
css/icon.png3.33KB1.06KB▼ 68.07%
css/expand.png2.75KB0.12KB▼ 95.49%