84% apple-passbook-gateway

Code Review | Apple Passbook Gateway

WordPress plugin Apple Passbook Gateway scored84%from 54 tests.

About plugin

  • Plugin page: apple-passbook-ga...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.4.2
  • WordPress version: 6.3.1
  • First release: Sep 30, 2012
  • Latest release: Oct 1, 2012
  • Number of updates: 6
  • Update frequency: every 0.2 days
  • Top authors: rushproject (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,257 total downloads


Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.01MB] [CPU: ▼2.16ms] Passed 4 tests

A check of server-side resources used by Apple Passbook Gateway
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0144.86 ▲3.78
Dashboard /wp-admin3.31 ▲0.0148.09 ▼0.36
Posts /wp-admin/edit.php3.36 ▲0.0150.05 ▲0.61
Add New Post /wp-admin/post-new.php5.89 ▲0.0194.37 ▼9.23
Media Library /wp-admin/upload.php3.24 ▲0.0135.94 ▲0.33
Passbook Gateway /wp-admin/options-general.php?page=passbook_options3.1830.50

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options

Browser metrics Passed 4 tests

An overview of browser requirements for Apple Passbook Gateway
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.34 ▲0.061.68 ▼0.0344.68 ▼1.15
Dashboard /wp-admin2,202 ▲255.62 ▼0.0493.11 ▲3.9542.47 ▲0.33
Posts /wp-admin/edit.php2,104 ▲41.98 ▲0.0340.73 ▲3.8136.21 ▼1.51
Add New Post /wp-admin/post-new.php1,530 ▲223.14 ▲0.08592.77 ▼87.5258.71 ▲4.21
Media Library /wp-admin/upload.php1,404 ▲74.12 ▼0.07105.84 ▼0.8248.86 ▲4.18
Passbook Gateway /wp-admin/options-general.php?page=passbook_options8242.0224.8029.61

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Smoke test failed, please fix the following
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=passbook_options
    • > Notice in wp-content/plugins/apple-passbook-gateway/passbook.php+95
    Trying to access array offset on value of type bool

SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found


Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need to be fixed:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === apple-passbook-gateway === )
The official readme.txt is a good inspiration

apple-passbook-gateway/passbook.php 92% from 13 tests

The principal PHP file in "Apple Passbook Gateway" v. 1.0 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("apple-passbook-gateway.php" instead of "passbook.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
There were no executable files found in this plugin212 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions11100.00%
▷ Anonymous functions00.00%
▷ Global constants2100.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