74% cforms2-old-tracking-db

Code Review | Old Tracking DB for cformsII

WordPress plugin Old Tracking DB for cformsII scored 74% from 54 tests.

About plugin

  • Plugin page: cforms2-old-track...
  • Plugin version: 0.3
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-5.6
  • WordPress version: 6.3.1
  • First release: Sep 8, 2017
  • Latest release: Dec 14, 2020
  • Number of updates: 11
  • Update frequency: every 108.5 days
  • Top authors: bgermann (100%)

Code review

54 tests

User reviews

1 review

Install metrics

60+ active / 1,422 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼1.51ms] Passed 4 tests

A check of server-side resources used by Old Tracking DB for cformsII
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0435.84 ▼10.11
Dashboard /wp-admin3.35 ▲0.0548.77 ▼0.49
Posts /wp-admin/edit.php3.40 ▲0.0446.53 ▲4.47
Add New Post /wp-admin/post-new.php5.93 ▲0.0495.87 ▲7.92
Media Library /wp-admin/upload.php3.27 ▲0.0436.11 ▲0.09

Server storage [IO: ▲0.04MB] [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: 4 new files
Database: 2 new tables, 6 new options
New tables
wp_cformssubmissions
wp_cformsdata
New WordPress options
can_compress_scripts
db_upgraded
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Old Tracking DB for cformsII
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.24 ▼1.114.51 ▲2.4241.66 ▼3.04
Dashboard /wp-admin2,209 ▲215.91 ▲0.84110.22 ▼6.3541.75 ▼2.44
Posts /wp-admin/edit.php2,089 ▲31.99 ▼0.0238.74 ▲2.4635.45 ▲0.81
Add New Post /wp-admin/post-new.php1,542 ▲2218.17 ▼4.88592.47 ▼62.6756.13 ▼2.72
Media Library /wp-admin/upload.php1,391 ▼04.20 ▼0.0395.29 ▼6.3343.82 ▼0.53

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 2 tables in the database
    • wp_cformsdata
    • wp_cformssubmissions
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however this is by no means an exhaustive test

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 take a closer look at the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/cforms2-old-tracking-db/Plugin.php:25

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
6 plugin tags: cforms, cformsii, tracking, cforms2, database...

cforms2-old-tracking-db/Plugin.php 92% from 13 tests

The primary PHP file in "Old Tracking DB for cformsII" version 0.3 is used by WordPress to initiate all plugin functionality
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("cforms2-old-tracking-db.php" instead of "Plugin.php")

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
No dangerous file extensions were detected204 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP24163204

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.60
Average class complexity55.00
▷ Minimum class complexity55.00
▷ Maximum class complexity55.00
Average method complexity5.00
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods120.00%
▷ Public methods360.00%
▷ Protected methods00.00%
▷ Private methods240.00%
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
There are no PNG files in this plugin