77% lead-overview

Code Review | CRM Lead Tracking

WordPress plugin CRM Lead Tracking scored77%from 54 tests.

About plugin

  • Plugin page: lead-overview
  • Plugin version: 1.1
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.0.2
  • WordPress version: 6.3.1
  • First release: Jan 7, 2019
  • Latest release: Jan 25, 2019
  • Number of updates: 22
  • Update frequency: every 7.9 days
  • Top authors: slashdigital (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /544 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼3.94ms] Passed 4 tests

Analyzing server-side resources used by CRM Lead Tracking
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0835.20 ▼3.73
Dashboard /wp-admin3.39 ▲0.0562.41 ▲4.16
Posts /wp-admin/edit.php3.51 ▲0.1552.98 ▲8.53
Add New Post /wp-admin/post-new.php5.97 ▲0.0985.10 ▼15.33
Media Library /wp-admin/upload.php3.32 ▲0.0936.30 ▼0.87
Lead Overview /wp-admin/admin.php?page=leovw3.2838.21
How to use /wp-admin/admin.php?page=leovw_readme3.2832.85

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

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

Browser metrics Passed 4 tests

A check of browser resources used by CRM Lead Tracking
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,844 ▲9814.73 ▲0.392.60 ▲0.9243.83 ▲2.18
Dashboard /wp-admin2,218 ▲405.61 ▼0.0698.01 ▼7.0040.19 ▲1.80
Posts /wp-admin/edit.php2,123 ▲201.99 ▲0.0337.66 ▲0.0731.75 ▲1.47
Add New Post /wp-admin/post-new.php1,557 ▲2218.26 ▲0.32640.82 ▲16.7686.22 ▲1.16
Media Library /wp-admin/upload.php1,417 ▲144.15 ▲0.03100.54 ▼4.3042.54 ▼0.90
Lead Overview /wp-admin/admin.php?page=leovw1,0581.8225.0028.06
How to use /wp-admin/admin.php?page=leovw_readme8061.9927.2129.44

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/admin.php?page=leovw
    • > Notice in wp-content/plugins/lead-overview/includes/class-tablelist.php+69
    Undefined offset: 0
    • > GET request to /wp-admin/admin.php?page=leovw
    • > Notice in wp-content/plugins/lead-overview/includes/class-tablelist.php+69
    Trying to get property 'contact_form_id' of non-object

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 8× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Warning
      require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/lead-overview/includes/class-tablelist.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/lead-overview/lead_overview.php:29
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/lead-overview/includes/class-tablelist.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/lead-overview/includes/functions.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/lead-overview/includes/hooks.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function leovw_getallforms() in wp-content/plugins/lead-overview/admin/listing-form.php:2
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/lead-overview/includes/class-tablelist.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/lead-overview/admin/admin.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
  • Contributors: Plugin contributors not specified
You can take inspiration from this readme.txt

lead-overview/lead_overview.php 77% from 13 tests

The main PHP script in "CRM Lead Tracking" version 1.1 is automatically included on every request by WordPress
It is important to fix the following:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("lead-overview.php" instead of "lead_overview.php")
  • Domain Path: The domain path folder does not exist ("/languages/")

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
Everything looks great! No dangerous files found in this plugin713 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP86841521
JavaScript23516192

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.61
Average class complexity9.00
▷ Minimum class complexity1.00
▷ Maximum class complexity17.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods8
▷ Static methods112.50%
▷ Public methods8100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions22
▷ Named functions2195.45%
▷ Anonymous functions14.55%
Constants5
▷ Global constants480.00%
▷ Class constants120.00%
▷ Public constants1100.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
There were not PNG files found in your plugin