89% pricing-table-by-ps

Code Review | Pricing Table by PS

WordPress plugin Pricing Table by PS scored 89% from 54 tests.

About plugin

  • Plugin page: pricing-table-by-ps
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-4.9
  • WordPress version: 5.9.2
  • First release: Feb 15, 2017
  • Latest release: Nov 19, 2017
  • Number of updates: 8
  • Update frequency: every 34.6 days
  • Top authors: PluginlySpeaking (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 568 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.13MB] [CPU: ▼297.36ms] Passed 4 tests

Analyzing server-side resources used by Pricing Table by PS
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.73 ▲0.2255.16 ▲3.62
Dashboard /wp-admin3.57 ▲0.1632.59 ▼0.69
Posts /wp-admin/edit.php3.79 ▲0.1538.62 ▲2.18
Add New Post /wp-admin/post-new.php7.04 ▲0.0792.82 ▼1,191.50
Media Library /wp-admin/upload.php3.45 ▲0.1523.96 ▲0.56
Pricing Table /wp-admin/edit.php?post_type=pspt_type3.5426.21
Add New /wp-admin/post-new.php?post_type=pspt_type3.7339.40

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 33 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Pricing Table by PS
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,943 ▲19916.52 ▲0.8810.28 ▲3.722.52 ▼0.13
Dashboard /wp-admin2,929 ▲686.05 ▼0.09119.28 ▼19.30150.85 ▼11.85
Posts /wp-admin/edit.php2,722 ▲283.25 ▲0.0264.76 ▼1.99141.64 ▲1.18
Add New Post /wp-admin/post-new.php1,686 ▲2515.99 ▼0.27405.09 ▼34.20152.23 ▼7.04
Media Library /wp-admin/upload.php1,735 ▲375.51 ▼0.02138.98 ▼2.43195.95 ▲6.88
Pricing Table /wp-admin/edit.php?post_type=pspt_type1,4073.1660.69109.16
Add New /wp-admin/post-new.php?post_type=pspt_type3,3364.2986.02199.34

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/pricing-table-by-ps/pricing-table-by-ps.php:12

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
These are user-side errors you should fix
    • > GET request to /wp-admin/post-new.php?post_type=pspt_type
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=5.9.2 1:31592 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-admin/post-new.php?post_type=pspt_type:244:36)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=5.9.2:2:30038)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=5.9.2:2:30340)" undefined
    • > GET request to /wp-admin/post-new.php?post_type=pspt_type
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=5.9.2 1:31592 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-admin/post-new.php?post_type=pspt_type:664:51)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=5.9.2:2:30038)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=5.9.2:2:30340)" undefined
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=pspt_type
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=5.9.2 1:31702 Uncaught TypeError: $(...).live is not a function

Optimizations

Plugin configuration Passed 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
5 plugin tags: table comparison, pricing plan, pricing table, plan table, shortcode

pricing-table-by-ps/pricing-table-by-ps.php Passed 13 tests

The principal PHP file in "Pricing Table by PS" v. 1.0 is loaded by WordPress automatically on each request
109 characters long description:
Build your pricing table or comparison table, select a pre-built layout and display it thanks to a shortcode.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Good job! No executable or dangerous file extensions detected3,154 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
CSS2472242,116
PHP1153191,038

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.34
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%
Functions27
▷ Named functions27100.00%
▷ Anonymous functions00.00%
Constants0
▷ 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
29 PNG files occupy 0.47MB with 0.25MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/table_comparison_layout/layout_11.PNG17.29KB8.76KB▼ 49.35%
img/pricing_table_layout/layout_24.PNG17.19KB7.83KB▼ 54.43%
img/pricing_table_layout/layout_42.PNG28.42KB12.24KB▼ 56.95%
img/pricing_table_layout/layout_25.PNG17.31KB7.85KB▼ 54.63%
img/table_comparison_layout/layout_39.PNG17.50KB8.75KB▼ 49.98%