94% add-new-default-avatar

Code Review | Add New Default Avatar

WordPress plugin Add New Default Avatar scored 94% from 54 tests.

About plugin

  • Plugin page: add-new-default-a...
  • Plugin version: 1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-4.4
  • WordPress version: 5.9.2
  • First release: Jun 10, 2010
  • Latest release: Feb 7, 2016
  • Number of updates: 35
  • Update frequency: every 59.1 days
  • Top authors: trepmal (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

1,000+ active / 45,850 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼302.12ms] Passed 4 tests

This is a short check of server-side resources used by Add New Default Avatar
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.0756.94 ▲8.83
Dashboard /wp-admin3.45 ▲0.0533.49 ▲0.10
Posts /wp-admin/edit.php3.68 ▲0.0437.98 ▲1.74
Add New Post /wp-admin/post-new.php6.92 ▼0.0592.66 ▼1,208.89
Media Library /wp-admin/upload.php3.33 ▲0.0428.40 ▼1.41

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 3 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for Add New Default Avatar
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,795 ▲4116.25 ▲0.606.76 ▲0.422.67 ▼0.32
Dashboard /wp-admin2,895 ▲346.00 ▼0.22118.66 ▼11.69153.15 ▼7.81
Posts /wp-admin/edit.php2,694 ▼03.23 ▼0.0163.17 ▼1.36141.67 ▼0.37
Add New Post /wp-admin/post-new.php1,752 ▲5621.04 ▼0.20450.61 ▼2.61159.20 ▼3.73
Media Library /wp-admin/upload.php1,695 ▼05.54 ▲0.03148.15 ▲2.71187.69 ▼123.51

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstall script ran successfully

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
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/add-new-default-avatar/kl_addnewdefaultavatar.php:32

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found


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
2 plugin tags: avatar, gravatar

add-new-default-avatar/kl_addnewdefaultavatar.php 92% from 13 tests

"Add New Default Avatar" version 1.4's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("add-new-default-avatar.php" instead of "kl_addnewdefaultavatar.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
No dangerous file extensions were detected127 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity19.00
▷ Minimum class complexity19.00
▷ Maximum class complexity19.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods9100.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

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG images were found in this plugin