90% letter-avatars

Code Review | Letter Avatars

WordPress plugin Letter Avatars scored90%from 54 tests.

About plugin

  • Plugin page: letter-avatars
  • Plugin version: 3.1.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-5.3.2
  • WordPress version: 6.3.1
  • First release: Jan 4, 2016
  • Latest release: Mar 3, 2020
  • Number of updates: 53
  • Update frequency: every 33.4 days
  • Top authors: seebeen (100%)

Code review

54 tests

User reviews

9 reviews

Install metrics

600+ active /15,644 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.03MB] [CPU: ▼2.33ms] Passed 4 tests

A check of server-side resources used by Letter Avatars
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.10147.23 ▲109.57
Dashboard /wp-admin3.33 ▲0.0353.52 ▲1.77
Posts /wp-admin/edit.php3.39 ▲0.0347.13 ▼2.13
Add New Post /wp-admin/post-new.php5.92 ▲0.0384.35 ▼10.07
Media Library /wp-admin/upload.php3.26 ▲0.0337.73 ▲1.10
Letter Avatars /wp-admin/options-general.php?page=sgi-letter-avatars3.2333.52

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 29 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Letter Avatars
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,801 ▲4014.33 ▼0.031.74 ▼0.0842.77 ▼2.49
Dashboard /wp-admin2,202 ▲225.62 ▼0.0183.79 ▼7.1037.19 ▼4.30
Posts /wp-admin/edit.php2,101 ▲12.01 ▲0.0234.42 ▼1.0336.76 ▼2.54
Add New Post /wp-admin/post-new.php1,531 ▲223.42 ▲0.44662.95 ▼17.7359.93 ▲0.44
Media Library /wp-admin/upload.php1,401 ▼24.20 ▼0.03112.28 ▲4.3546.38 ▼0.67
Letter Avatars /wp-admin/options-general.php?page=sgi-letter-avatars1,2302.4651.3634.01

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
10 plugin tags: gravatar, letter, buddypress, wp-user-avatar, buddypress-avatar...

letter-avatars/letter-avatars.php 92% from 13 tests

"Letter Avatars" version 3.1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Requires PHP: Required version must be the same as the one declared in readme.txt ("7.0.0" instead of "7.0")

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
Success! There were no dangerous files found in this plugin1,472 lines of code in 25 files:
LanguageFilesBlank linesComment linesLines of code
PHP185194321,361
CSS39045
JavaScript236145
JSON10011
LESS15010

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity11.80
▷ Minimum class complexity1.00
▷ Maximum class complexity44.00
Average method complexity2.80
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces5
Interfaces0
Traits0
Classes10
▷ Abstract classes00.00%
▷ Concrete classes10100.00%
▷ Final classes00.00%
Methods61
▷ Static methods34.92%
▷ Public methods6098.36%
▷ Protected methods00.00%
▷ Private methods11.64%
Functions13
▷ Named functions1292.31%
▷ Anonymous functions17.69%
Constants11
▷ Global constants545.45%
▷ Class constants654.55%
▷ Public constants6100.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
There are no PNG files in this plugin