83% auto-files

Code Review | Auto Files

WordPress plugin Auto Files scored83%from 54 tests.

About plugin

  • Plugin page: auto-files
  • Plugin version: 0.8
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-4.1
  • WordPress version: 6.3.1
  • First release: Apr 24, 2014
  • Latest release: Jan 31, 2015
  • Number of updates: 11
  • Update frequency: every 25.6 days
  • Top authors: kaisercrazy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

90+ active /5,138 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼1.02MB] [CPU: ▼25.01ms] Passed 4 tests

An overview of server-side resources used by Auto Files
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.06 ▼1.405.13 ▼33.69
Dashboard /wp-admin3.34 ▲0.0350.81 ▲1.33
Posts /wp-admin/edit.php3.39 ▲0.0346.48 ▼2.70
Add New Post /wp-admin/post-new.php3.16 ▼2.7236.33 ▼64.97
Media Library /wp-admin/upload.php3.26 ▲0.0335.76 ▲3.25

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Auto Files
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5814.44 ▲0.041.81 ▲0.0443.44 ▲4.10
Dashboard /wp-admin2,206 ▲184.88 ▼0.01108.38 ▲7.6539.10 ▼7.89
Posts /wp-admin/edit.php2,086 ▼32.04 ▲0.0334.49 ▼7.4733.68 ▼2.77
Add New Post /wp-admin/post-new.php6,256 ▲4,71921.79 ▲3.60842.62 ▲251.5653.86 ▼3.52
Media Library /wp-admin/upload.php1,391 ▼04.22 ▼0.0697.42 ▼1.1343.74 ▲2.19

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

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

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
Please take a closer look at the following
  • 2× PHP files output text when accessed directly:
    • > /wp-content/plugins/auto-files/autofiles.php
    • > /wp-content/plugins/auto-files/metaboxes.php

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)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that require attention:
  • Tags: Please reduce the number of tags, currently 17 tag instead of maximum 10
  • Screenshots: Add an image for screenshot #1 (Files Section)
The official readme.txt is a good inspiration

auto-files/autofiles.php 92% from 13 tests

The main PHP script in "Auto Files" version 0.8 is automatically included on every request by WordPress
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("auto-files.php" instead of "autofiles.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected324 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP22518176
PO File3151581
CSS14467

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.36
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%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png4.24KB2.02KB▼ 52.36%