94% advanced-schedule-posts

Code Review | Advanced Schedule Posts

WordPress plugin Advanced Schedule Posts scored 94% from 54 tests.

About plugin

  • Plugin page: advanced-schedule...
  • Plugin version: 2.1.8
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.0-5.8
  • WordPress version: 5.9.2
  • First release: Dec 25, 2014
  • Latest release: Aug 24, 2021
  • Number of updates: 32
  • Update frequency: every 76.1 days
  • Top authors: hijiri (100%)

Code review

54 tests

User reviews

8 reviews

Install metrics

5,000+ active / 38,200 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

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

Server-side resources used by Advanced Schedule Posts
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.0655.75 ▲5.93
Dashboard /wp-admin3.49 ▲0.0836.18 ▼0.75
Posts /wp-admin/edit.php3.71 ▲0.0740.07 ▼17.53
Add New Post /wp-admin/post-new.php6.96 ▼0.01108.09 ▼1,354.36
Media Library /wp-admin/upload.php3.37 ▲0.0824.36 ▼9.12
List /wp-admin/admin.php?page=hasp-list3.4225.75
Settings /wp-admin/admin.php?page=hasp-settings3.3926.44

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 13 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Advanced Schedule Posts: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,838 ▲9416.12 ▲0.426.16 ▲0.182.07 ▼0.12
Dashboard /wp-admin2,943 ▲856.69 ▲0.36118.48 ▼17.62164.33 ▼0.39
Posts /wp-admin/edit.php2,767 ▲733.30 ▲0.0665.88 ▼2.66143.98 ▼6.91
Add New Post /wp-admin/post-new.php1,902 ▲14219.80 ▼2.07421.55 ▼14.79209.95 ▲19.96
Media Library /wp-admin/upload.php1,743 ▲455.73 ▲0.20150.55 ▲6.34198.55 ▼23.00
List /wp-admin/admin.php?page=hasp-list1,2893.1860.25100.49
Settings /wp-admin/admin.php?page=hasp-settings1,2213.1959.04102.07

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Uninstall script ran successfully

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
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 5× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/advanced-schedule-posts/admin/list.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/advanced-schedule-posts/advanced-schedule-posts.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_type() in wp-content/plugins/advanced-schedule-posts/include/meta_box.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/advanced-schedule-posts/admin/settings.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_type() in wp-content/plugins/advanced-schedule-posts/include/meta_box_block.php:5

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

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
3 plugin tags: schedule, post, admin

advanced-schedule-posts/advanced-schedule-posts.php Passed 13 tests

The main file in "Advanced Schedule Posts" v. 2.1.8 serves as a complement to information provided in readme.txt and as the entry point to the plugin
95 characters long description:
Allows you to set datetime of expiration and to set schedule which overwrites the another post.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Success! There were no dangerous files found in this plugin3,352 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript22342952,003
PHP51872001,209
PO File1363788
CSS161334
Markdown113018

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity186.00
▷ Minimum class complexity186.00
▷ Maximum class complexity186.00
Average method complexity5.62
▷ Minimum method complexity1.00
▷ Maximum method complexity31.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods40
▷ Static methods00.00%
▷ Public methods3997.50%
▷ Protected methods00.00%
▷ Private methods12.50%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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 files were detected