63% contact-list

Code Review | Contact List – Premium Staff Listing, Business Directory & Address Book

WordPress plugin Contact List – Premium Staff Listing, Business Directory & Address Book scored63%from 54 tests.

About plugin

  • Plugin page: contact-list
  • Plugin version: 2.9.82
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4.0-6.4
  • WordPress version: 6.3.1
  • First release: Jul 15, 2018
  • Latest release: Nov 21, 2023
  • Number of updates: 292
  • Update frequency: every 6.7 days
  • Top authors: anssilaitila (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

900+ active /36,712 total downloads

Benchmarks

Plugin footprint 47% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲5.90MB] [CPU: ▲30.87ms] 75% from 4 tests

An overview of server-side resources used by Contact List – Premium Staff Listing, Business Directory & Address Book
Please have a look at the following items
  • Extra RAM: Try to keep extra memory usage under 5MB (currently 5.90MB on /wp-admin/edit.php?post_type=contact&page=contact-list-import)
PageMemory (MB)CPU Time (ms)
Home /9.27 ▲5.8072.59 ▲29.61
Dashboard /wp-admin9.29 ▲5.9887.23 ▲35.66
Posts /wp-admin/edit.php9.29 ▲5.9390.46 ▲36.18
Add New Post /wp-admin/post-new.php11.76 ▲5.87121.18 ▲22.03
Media Library /wp-admin/upload.php9.29 ▲6.0682.32 ▲47.64
All Contacts /wp-admin/edit.php?post_type=contact9.2975.50
Help / Support /wp-admin/edit.php?post_type=contact&page=contact-list-support9.2968.90
Mail log /wp-admin/edit.php?post_type=contact&page=contact-list-mail-log9.2974.31
Printable list /wp-admin/edit.php?post_type=contact&page=contact-list-printable9.2965.99
Export contacts /wp-admin/edit.php?post_type=contact&page=contact-list-export9.2974.90
Contact List /wp-admin/options-general.php?page=contact-list9.2977.78
Groups /wp-admin/edit-tags.php?taxonomy=contact-group&post_type=contact9.2970.28
Send email /wp-admin/edit.php?post_type=contact&page=contact-list-send-email9.2968.03
Freemius Debug [v.2.6.0] /wp-admin/admin.php?page=freemius9.2966.37
Import contacts /wp-admin/edit.php?post_type=contact&page=contact-list-import9.2966.88

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 255 new files
Database: 2 new tables, 13 new options
New tables
wp_contact_list_log
wp_cl_sent_mail_log
New WordPress options
db_upgraded
fs_accounts
contact-list-sc
fs_active_plugins
contact_list_settings
contact_list_metadata_fixed_1000
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
...

Browser metrics Passed 4 tests

Checking browser requirements for Contact List – Premium Staff Listing, Business Directory & Address Book
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,983 ▲19613.85 ▼0.918.84 ▲6.7427.70 ▼16.14
Dashboard /wp-admin2,294 ▲1175.55 ▼0.0897.58 ▲2.0148.30 ▲1.32
Posts /wp-admin/edit.php2,200 ▲1002.03 ▼0.0640.89 ▼0.7442.86 ▲2.94
Add New Post /wp-admin/post-new.php1,594 ▲6822.03 ▼1.22720.56 ▲112.7453.09 ▼17.56
Media Library /wp-admin/upload.php1,496 ▲934.30 ▲0.1097.56 ▼3.4049.34 ▲5.45
All Contacts /wp-admin/edit.php?post_type=contact1,3902.1638.4154.66
Help / Support /wp-admin/edit.php?post_type=contact&page=contact-list-support1,0571.7029.8739.35
Mail log /wp-admin/edit.php?post_type=contact&page=contact-list-mail-log9171.6929.6132.52
Printable list /wp-admin/edit.php?post_type=contact&page=contact-list-printable9731.8125.4438.36
Export contacts /wp-admin/edit.php?post_type=contact&page=contact-list-export1,0351.9229.5838.95
Contact List /wp-admin/options-general.php?page=contact-list1,1061.6927.4461.82
Groups /wp-admin/edit-tags.php?taxonomy=contact-group&post_type=contact1,3572.3633.0034.13
Send email /wp-admin/edit.php?post_type=contact&page=contact-list-send-email9611.8125.4136.96
Freemius Debug [v.2.6.0] /wp-admin/admin.php?page=freemius1,1611.6926.3332.36
Import contacts /wp-admin/edit.php?post_type=contact&page=contact-list-import1,0321.8024.9936.77

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Uninstall procedure validation failed for this plugin
    • > Notice in wp-content/plugins/contact-list/freemius/includes/class-freemius.php+8546
    Undefined property: stdClass::$plugins
  • The plugin did not uninstall successfully, leaving 2 tables in the database
    • wp_contact_list_log
    • wp_cl_sent_mail_log
  • This plugin did not uninstall successfully, leaving 13 options in the database
    • contact-list-sc
    • contact_list_version
    • contact_list_settings
    • fs_accounts
    • fs_debug_mode
    • fs_active_plugins
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • contact_list_metadata_fixed_1000
    • ...

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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 server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'ContactListPublicHooks' not found in wp-content/plugins/contact-list/templates/contact-card.php:19
    • > PHP Notice
      Undefined variable: id in wp-content/plugins/contact-list/templates/contact-card.php on line 17

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Tags: Please delete some tags, you are using 12 tag instead of maximum 10
You can look at the official readme.txt

contact-list/contact-list.php Passed 13 tests

The primary PHP file in "Contact List – Premium Staff Listing, Business Directory & Address Book" version 2.9.82 is used by WordPress to initiate all plugin functionality
72 characters long description:
Easily display contact information on your site with this simple plugin.

Code Analysis 95% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin52,185 lines of code in 195 files:
LanguageFilesBlank linesComment linesLines of code
PHP1569,48117,86743,119
PO File61,5184,1003,804
SVG81012,702
CSS191202,363
JavaScript63459197

PHP code 0% from 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Please fix the following
  • Class cyclomatic complexity has to be reduced to less than 1000 (currently 3,096)
  • Method cyclomatic complexity has to be reduced to less than 100 (currently 177)
Cyclomatic complexity
Average complexity per logical line of code0.60
Average class complexity64.19
▷ Minimum class complexity1.00
▷ Maximum class complexity3,096.00
Average method complexity4.98
▷ Minimum method complexity1.00
▷ Maximum method complexity177.00
Code structure
Namespaces0
Interfaces1
Traits0
Classes87
▷ Abstract classes22.30%
▷ Concrete classes8597.70%
▷ Final classes00.00%
Methods1,425
▷ Static methods24417.12%
▷ Public methods1,02071.58%
▷ Protected methods171.19%
▷ Private methods38827.23%
Functions108
▷ Named functions108100.00%
▷ Anonymous functions00.00%
Constants153
▷ Global constants10669.28%
▷ Class constants4730.72%
▷ Public constants47100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/search-form-sample.png5.89KB4.30KB▼ 26.96%
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%