84% avatar-project

Code Review | Avatar Project

WordPress plugin Avatar Project scored84%from 54 tests.

About plugin

  • Plugin page: avatar-project
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-4.9
  • WordPress version: 6.3.1
  • First release: Nov 16, 2017
  • Latest release: Nov 16, 2017
  • Number of updates: 9
  • Update frequency: N/A
  • Top authors: justnorris (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,503 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

An overview of server-side resources used by Avatar Project
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.54 ▼1.50
Dashboard /wp-admin3.31 ▲0.0143.92 ▼6.46
Posts /wp-admin/edit.php3.36 ▲0.0146.29 ▼1.85
Add New Post /wp-admin/post-new.php5.89 ▲0.0189.29 ▼3.92
Media Library /wp-admin/upload.php3.24 ▲0.0136.83 ▲1.86

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 423 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-posts
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Avatar Project
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲4313.31 ▼1.121.63 ▼0.4540.58 ▼5.89
Dashboard /wp-admin2,206 ▲214.86 ▼0.03110.28 ▲5.5742.61 ▼1.96
Posts /wp-admin/edit.php2,089 ▼02.00 ▼0.0538.99 ▲0.3335.17 ▼3.62
Add New Post /wp-admin/post-new.php1,542 ▲918.30 ▼4.75622.70 ▼64.9460.49 ▲7.49
Media Library /wp-admin/upload.php1,391 ▲34.18 ▲0.0193.87 ▼4.6941.94 ▼1.72

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments

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
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/avatar-project/avatar-project.php:15

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

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
  • Screenshots: No descriptions were found for these screenshots #1, #2, #3, #4, #5, #6 in avatar-project/assets to your readme.txt
Please take inspiration from this readme.txt

avatar-project/avatar-project.php Passed 13 tests

The main PHP script in "Avatar Project" version 1.0.2 is automatically included on every request by WordPress
47 characters long description:
Custom default avatars for your WordPress site!

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin2,027 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
JSON1001,827
PHP36172144
JavaScript14949
Markdown1307

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.48
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
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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