78% ajs-footnotes

Code Review | AJS Footnotes

WordPress plugin AJS Footnotes scored78%from 54 tests.

About plugin

  • Plugin page: ajs-footnotes
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.4
  • WordPress version: 6.3.1
  • First release: Apr 1, 2013
  • Latest release: Apr 7, 2013
  • Number of updates: 15
  • Update frequency: every 2.3 days
  • Top authors: ajseidl (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

40+ active /1,943 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

Server metrics [RAM: ▲0.15MB] [CPU: ▼5.06ms] Passed 4 tests

An overview of server-side resources used by AJS Footnotes
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1440.11 ▲0.27
Dashboard /wp-admin3.45 ▲0.1448.28 ▼0.01
Posts /wp-admin/edit.php3.56 ▲0.2044.56 ▼3.77
Add New Post /wp-admin/post-new.php6.05 ▲0.1679.68 ▼16.74
Media Library /wp-admin/upload.php3.37 ▲0.1438.04 ▲1.79
AJS Footnotes /wp-admin/options-general.php?page=ajs-footnotes/ajs_footnotes.php3.3330.38

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 26 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-comments
ajs_footnote_options
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

AJS Footnotes: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,888 ▲12713.81 ▼0.548.47 ▲6.7042.82 ▼1.04
Dashboard /wp-admin2,210 ▲335.71 ▲0.1895.67 ▲1.5342.78 ▼1.84
Posts /wp-admin/edit.php2,112 ▲122.19 ▲0.1935.56 ▼3.7631.64 ▼5.85
Add New Post /wp-admin/post-new.php1,537 ▼123.81 ▲0.87675.51 ▲66.8636.57 ▼23.27
Media Library /wp-admin/upload.php1,409 ▲94.36 ▲0.15110.19 ▲11.9344.73 ▲0.22
AJS Footnotes /wp-admin/options-general.php?page=ajs-footnotes/ajs_footnotes.php2,9332.4161.7947.57

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • ajs_footnote_options
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/options-general.php?page=ajs-footnotes/ajs_footnotes.php
    • > Warning in wp-content/plugins/ajs-footnotes/ajs_footnotes.php+358
    count(): Parameter must be an array or an object that implements Countable

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/ajs-footnotes/ajs_footnotes.php:123

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)
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: citataions, bibliography, footnotes

ajs-footnotes/ajs_footnotes.php 92% from 13 tests

"AJS Footnotes" version 1.0'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: The principal plugin file should be the same as the plugin slug ("ajs-footnotes.php" instead of "ajs_footnotes.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin2,681 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
CSS476661,319
PHP254134743
JavaScript3135132619

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity29.00
▷ Minimum class complexity21.00
▷ Maximum class complexity37.00
Average method complexity4.50
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods16
▷ Static methods00.00%
▷ Public methods956.25%
▷ Protected methods00.00%
▷ Private methods743.75%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
14 PNG files occupy 0.10MB with 0.04MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/wp-admin/images/ui-bg_flat_75_ffffff_40x100.png0.20KB0.08KB▼ 58.17%
css/wp-admin/images/ui-bg_highlight-hard_60_208bbc_1x100.png0.31KB0.15KB▼ 51.26%
css/wp-admin/images/ui-bg_highlight-hard_85_208bbc_1x100.png0.31KB0.16KB▼ 49.53%
css/wp-admin/images/ui-icons_222222_256x240.png6.76KB4.17KB▼ 38.24%
css/wp-admin/images/ui-icons_2e83ff_256x240.png4.44KB4.17KB▼ 6.02%