84% cats-job-listings

Code Review | CATS Job Listings

WordPress plugin CATS Job Listings scored84%from 54 tests.

About plugin

  • Plugin page: cats-job-listings
  • Plugin version: 2.0.6
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-5.8
  • WordPress version: 6.3.1
  • First release: Feb 3, 2016
  • Latest release: Dec 6, 2021
  • Number of updates: 46
  • Update frequency: every 46.4 days
  • Top authors: catssoft (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

300+ active /5,848 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼5.75ms] Passed 4 tests

An overview of server-side resources used by CATS Job Listings
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0337.23 ▼1.99
Dashboard /wp-admin3.35 ▲0.0048.35 ▼10.71
Posts /wp-admin/edit.php3.40 ▲0.0445.04 ▼7.64
Add New Post /wp-admin/post-new.php5.93 ▲0.0488.53 ▼2.64
Media Library /wp-admin/upload.php3.27 ▲0.0434.85 ▼0.69
CATS Job Listings /wp-admin/options-general.php?page=cats-job-listings3.2429.41

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 8 new options
New WordPress options
db_upgraded
cats-version
cats-options
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for CATS Job Listings
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲4714.34 ▼0.381.59 ▼0.0438.64 ▼9.14
Dashboard /wp-admin2,196 ▲285.51 ▼0.1483.47 ▼3.7635.96 ▼8.85
Posts /wp-admin/edit.php2,104 ▲252.02 ▲0.0538.43 ▲2.2732.66 ▼5.58
Add New Post /wp-admin/post-new.php1,529 ▲123.33 ▲0.15578.94 ▼44.7868.42 ▼0.21
Media Library /wp-admin/upload.php1,401 ▲14.18 ▲0.08101.89 ▼5.3840.78 ▼4.21
CATS Job Listings /wp-admin/options-general.php?page=cats-job-listings8651.9922.4540.97

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
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 8 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • cats-version
    • db_upgraded
    • cats-options
    • widget_recent-comments
    • widget_theysaidso_widget

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)
Even though no errors were found, 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 items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/cats-job-listings/CATSJobListing.php:32

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Tags: There are too many tags (13 tag instead of maximum 10)
The official readme.txt might help

cats-job-listings/CATSJobListing.php 92% from 13 tests

Analyzing the main PHP file in "CATS Job Listings" version 2.0.6
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("cats-job-listings.php" instead of "CATSJobListing.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin220 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP33513220

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity8.00
▷ Minimum class complexity3.00
▷ Maximum class complexity13.00
Average method complexity2.27
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods12
▷ Static methods00.00%
▷ Public methods1083.33%
▷ Protected methods00.00%
▷ Private methods216.67%
Functions2
▷ Named functions150.00%
▷ Anonymous functions150.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG files were detected