83% ajax-cpt-and-taxonomy-filter

Code Review | Ajax CPT and Taxonomy Filter

WordPress plugin Ajax CPT and Taxonomy Filter scored83%from 54 tests.

About plugin

  • Plugin page: ajax-cpt-and-taxo...
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-5.9.3
  • WordPress version: 6.3.1
  • First release: May 7, 2022
  • Latest release: May 7, 2022
  • Number of updates: 2
  • Update frequency: every 3.5 days
  • Top authors: shahala (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /397 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.02MB] [CPU: ▼3.48ms] Passed 4 tests

Analyzing server-side resources used by Ajax CPT and Taxonomy Filter
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0437.10 ▼2.45
Dashboard /wp-admin3.33 ▼0.0146.50 ▼14.68
Posts /wp-admin/edit.php3.38 ▲0.0350.79 ▲4.93
Add New Post /wp-admin/post-new.php5.91 ▲0.0393.22 ▲0.02
Media Library /wp-admin/upload.php3.26 ▲0.0336.13 ▲3.21

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Ajax CPT and Taxonomy Filter
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,820 ▲5914.35 ▲0.002.19 ▲0.6038.53 ▼2.55
Dashboard /wp-admin2,195 ▲155.60 ▼0.0789.00 ▲1.4143.05 ▼2.29
Posts /wp-admin/edit.php2,103 ▲32.15 ▲0.1739.34 ▲4.6534.95 ▲2.87
Add New Post /wp-admin/post-new.php1,535 ▲918.25 ▼5.35602.74 ▼69.2665.71 ▲5.62
Media Library /wp-admin/upload.php1,403 ▲34.22 ▲0.0096.61 ▲0.3944.07 ▼0.84

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means 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
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ajax-cpt-and-taxonomy-filter/ajax-cpt-taxonomy-filter.php:23
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_the_permalink() in wp-content/plugins/ajax-cpt-and-taxonomy-filter/main-template.php:2

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)
No browser issues were found

Optimizations

Plugin configuration 86% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: portfolio, wordpres, cpt, filter, ajax...

ajax-cpt-and-taxonomy-filter/ajax-cpt-taxonomy-filter.php 69% from 13 tests

Analyzing the main PHP file in "Ajax CPT and Taxonomy Filter" version 1.0.0
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("ajax-cpt-and-taxonomy-filter.php" instead of "ajax-cpt-taxonomy-filter.php")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Requires at least: Required version must match the one declared in readme.txt ("5.7" instead of "5.2")
  • Requires PHP: Required version must match the one declared in readme.txt ("7.4" instead of "7.2")

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
There were no executable files found in this plugin391 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP21522158
CSS11310156
JavaScript1261377

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.20
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%
Functions3
▷ Named functions3100.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 files were detected