93% ab-api-call-logger

Code Review | API Request Collector

WordPress plugin API Request Collector scored 93% from 54 tests.

About plugin

  • Plugin page: ab-api-call-logger
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.1+
  • WordPress version: 5.9.2
  • First release: Apr 30, 2013
  • Latest release: Apr 30, 2013
  • Number of updates: 7
  • Update frequency: N/A
  • Top authors: technosailor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 987 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

Analyzing server-side resources used by API Request Collector
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.4158.72 ▲41.18
Dashboard /wp-admin3.42 ▲0.0239.01 ▲4.27
Posts /wp-admin/edit.php3.65 ▲0.0142.49 ▲4.21
Add New Post /wp-admin/post-new.php6.89 ▼0.0896.29 ▼1,189.72
Media Library /wp-admin/upload.php3.30 ▲0.0128.57 ▲2.27

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 3 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for API Request Collector
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,812 ▲5815.69 ▼0.346.46 ▲0.642.74 ▼0.06
Dashboard /wp-admin2,894 ▲336.12 ▼0.06116.23 ▼13.64201.02 ▼16.01
Posts /wp-admin/edit.php2,710 ▲193.24 ▲0.0064.00 ▼3.59136.52 ▼8.73
Add New Post /wp-admin/post-new.php1,781 ▲11422.25 ▲3.60438.71 ▲29.06192.43 ▲26.18
Media Library /wp-admin/upload.php1,714 ▲225.52 ▼0.01152.74 ▲7.91236.65 ▲23.63

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/ab-api-call-logger/ab-api-logger.php:18

User-side errors Passed 1 test

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


Plugin configuration 86% from 29 tests

readme.txt 81% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Please fix the following attributes:
  • Tested up to: Version format is invalid
  • Plugin Name: You should set the name of your plugin on the first line ( === ab-api-call-logger === )
  • Screenshots: Screenshot #1 (This screenshot (properly obfuscated to protect the innocent) shows a clickable list of API calls performed.) image required
You can look at the official readme.txt

ab-api-call-logger/ab-api-logger.php 92% from 13 tests

"API Request Collector" version 0.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("ab-api-call-logger.php" instead of "ab-api-logger.php")

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
No dangerous file extensions were detected70 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity8.00
▷ Minimum class complexity8.00
▷ Maximum class complexity8.00
Average method complexity2.40
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions00.00%
▷ Anonymous functions00.00%
▷ 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
1 PNG file occupies 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png25.08KB11.37KB▼ 54.65%