89% first-data-for-pmpro

Code Review | First Data for Paid Memberships Pro

WordPress plugin First Data for Paid Memberships Pro scored89%from 54 tests.

About plugin

  • Plugin page: first-data-for-pmpro
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.9
  • WordPress version: 6.3.1
  • First release: Jan 14, 2016
  • Latest release: Jan 18, 2018
  • Number of updates: 11
  • Update frequency: every 66.8 days
  • Top authors: cardpaysolutions (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,011 total downloads

Benchmarks

Plugin footprint 83% 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.01MB] [CPU: ▼7.95ms] Passed 4 tests

A check of server-side resources used by First Data for Paid Memberships Pro
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0136.55 ▼6.98
Dashboard /wp-admin3.32 ▲0.0145.05 ▼15.31
Posts /wp-admin/edit.php3.37 ▲0.0147.39 ▼4.53
Add New Post /wp-admin/post-new.php5.90 ▲0.0192.78 ▼4.97
Media Library /wp-admin/upload.php3.24 ▲0.0135.09 ▲0.41

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for First Data for Paid Memberships Pro
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.22 ▼1.451.61 ▼0.1442.89 ▼10.40
Dashboard /wp-admin2,206 ▲214.85 ▼0.25108.18 ▼5.5236.13 ▼8.93
Posts /wp-admin/edit.php2,092 ▼01.99 ▼0.0638.85 ▼2.0634.73 ▲2.72
Add New Post /wp-admin/post-new.php1,533 ▲518.01 ▼0.23615.77 ▼9.4773.01 ▲24.43
Media Library /wp-admin/upload.php1,388 ▼04.21 ▲0.0292.49 ▼7.8439.77 ▼8.56

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Everything seems fine, however this is by no means an exhaustive test

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 93% from 29 tests

readme.txt Passed 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
10 plugin tags: subscription payment, global gateway e4, linkpoint, first data, payment gateway...

first-data-for-pmpro/pmpro-firstdata-gateway.php 85% from 13 tests

The primary PHP file in "First Data for Paid Memberships Pro" version 1.0.1 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: Name the main plugin file the same as the plugin slug ("first-data-for-pmpro.php" instead of "pmpro-firstdata-gateway.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin584 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP369185584

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity23.67
▷ Minimum class complexity2.00
▷ Maximum class complexity52.00
Average method complexity3.62
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods26
▷ Static methods519.23%
▷ Public methods26100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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
1 PNG file occupies 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/fd_logo.png8.35KB3.66KB▼ 56.17%