72% advanced-footnotes

Code Review | Advanced Footnotes

WordPress plugin Advanced Footnotes scored 72% from 54 tests.

About plugin

  • Plugin page: advanced-footnotes
  • Plugin version: 1.1.2
  • PHP version: 7.4.16
  • WordPress version: 5.8.1
  • First release: Jun 1, 2018
  • Latest release: Jun 2, 2018
  • Number of updates: 8
  • Update frequency: every 10.1 days
  • Top authors: yutonet (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active / 640 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.08MB] [CPU: ▼140.45ms] Passed 4 tests

An overview of server-side resources used by Advanced Footnotes
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.91 ▲0.1934.21 ▲10.18
Dashboard /wp-admin3.14 ▲0.0844.80 ▼0.37
Posts /wp-admin/edit.php3.19 ▲0.0835.56 ▼6.80
Add New Post /wp-admin/post-new.php5.50 ▲0.0795.34 ▼548.14
Media Library /wp-admin/upload.php3.08 ▲0.0733.19 ▼6.48
Advanced Footnotes /wp-admin/options-general.php?page=advanced_footnotes3.0429.11

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 11 new files
Database: no new tables, 1 new option
New WordPress options
afn_opts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Advanced Footnotes
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,819 ▲22416.25 ▲0.8012.13 ▲3.5244.77 ▲1.10
Dashboard /wp-admin2,975 ▲416.12 ▲0.16138.33 ▼7.65114.37 ▲4.36
Posts /wp-admin/edit.php2,746 ▲72.70 ▲0.0065.74 ▼3.0693.48 ▲10.57
Add New Post /wp-admin/post-new.php1,620 ▼5221.56 ▲2.69268.18 ▼99.77111.34 ▼4.23
Media Library /wp-admin/upload.php1,817 ▲105.05 ▲0.04147.02 ▼11.14116.90 ▲2.23
Advanced Footnotes /wp-admin/options-general.php?page=advanced_footnotes1,1712.1059.3085.01

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 1 option
    • afn_opts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Almost there, just fix the following server-side errors
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=advanced_footnotes
    • > Notice in wp-content/plugins/advanced-footnotes/options.php+199
    Undefined index: customcss
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=advanced_footnotes
    • > Notice in wp-content/plugins/advanced-footnotes/options.php+202
    Undefined variable: default
    • > GET request to /wp-admin/options-general.php?page=advanced_footnotes
    • > Notice in wp-content/plugins/advanced-footnotes/options.php+189
    Undefined index: var_footnotesymbol

SRP 0% 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
  • 2× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/advanced-footnotes/options-page.php
    • > /wp-content/plugins/advanced-footnotes/advanced-footnotes.php
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/advanced-footnotes/options.php:277

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

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: references, articles, footnotes, academic

advanced-footnotes/advanced-footnotes.php 92% from 13 tests

The entry point to "Advanced Footnotes" version 1.1.2 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Text Domain: The text domain follows the same naming rules as the plugin slug: lowercase characters and dashes

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin618 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP36811442
JavaScript3224164
LESS11011
CSS1001

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity15.00
▷ Minimum class complexity15.00
▷ Maximum class complexity15.00
Average method complexity3.33
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods6100.00%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin