10% banti-album-proofing

Code Review | Banti Album Proofing

WordPress plugin Banti Album Proofing scored 10% from 54 tests.

About plugin

  • Plugin page: banti-album-proofing
  • Plugin version: 1.2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.1-4.7.5
  • WordPress version: 6.3.1
  • First release: Apr 5, 2013
  • Latest release: Nov 19, 2016
  • Number of updates: 26
  • Update frequency: every 58.4 days
  • Top authors: bantionline (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active / 2,080 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The following installer errors require your attention
  • The plugin cannot be installed
    • > User deprecated in wp-includes/functions.php+5453
    Function wpdb::escape is deprecated since version 3.6.0! Use wpdb::prepare() or esc_sql() instead.

Server metrics [RAM: ▼1.23MB] [CPU: ▼41.42ms] Passed 4 tests

An overview of server-side resources used by Banti Album Proofing
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.74 ▼0.7213.57 ▼28.48
Dashboard /wp-admin2.78 ▼0.5215.36 ▼30.58
Posts /wp-admin/edit.php2.78 ▼0.5717.09 ▼27.70
Add New Post /wp-admin/post-new.php2.78 ▼3.1116.34 ▼78.92
Media Library /wp-admin/upload.php2.78 ▼0.4516.17 ▼15.93
Banti /wp-admin/admin.php?page=banti-album-proofing/banti-album-proofing.php2.7815.77
Help /wp-admin/admin.php?page=help2.7815.76
Settings /wp-admin/admin.php?page=settings2.7815.35

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 9 new files
Database: 1 new table, 6 new options
New tables
wp_banti_settings_tbl
New WordPress options
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Banti Album Proofing
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,830 ▲9513.27 ▼1.011.67 ▼0.0144.36 ▲5.52
Dashboard /wp-admin2,239 ▲504.94 ▼0.0197.62 ▼22.7993.27 ▲50.92
Posts /wp-admin/edit.php2,122 ▲332.03 ▼0.0135.22 ▼1.9231.14 ▼0.76
Add New Post /wp-admin/post-new.php1,538 ▲423.65 ▲0.36744.22 ▲14.3850.75 ▼5.77
Media Library /wp-admin/upload.php1,421 ▲304.22 ▼0.0197.50 ▲0.1047.56 ▲2.83
Banti /wp-admin/admin.php?page=banti-album-proofing/banti-album-proofing.php8732.0524.3427.54
Help /wp-admin/admin.php?page=help8912.0124.3926.52
Settings /wp-admin/admin.php?page=settings8492.0627.0229.21

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Uninstall procedure validation failed for this plugin
    • > Notice in wp-content/plugins/banti-album-proofing/banti-album-proofing.php+127
    Trying to get property 'username' of non-object
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
  • 8 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=settings
    • > Notice in wp-content/plugins/banti-album-proofing/banti-admin-settings.php+35
    Trying to get property 'username' of non-object
  • 27 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=settings
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=settings
    • > Notice in wp-content/plugins/banti-album-proofing/banti-admin-settings.php+39
    Trying to get property 'password' of non-object
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=settings
    • > Notice in wp-content/plugins/banti-album-proofing/banti-admin-settings.php+6
    Undefined index: username

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
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/banti-album-proofing/banti-album-help.php
  • 3× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/banti-album-proofing/banti-admin-settings.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/banti-album-proofing/banti-album-proofing.php:36
    • > PHP Warning
      Use of undefined constant BANTI_PLUGIN_URL - assumed 'BANTI_PLUGIN_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/banti-album-proofing/banti-album-help.php on line 50

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 93% 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 to be fixed:
  • Donate link: Invalid URI found ("")
You can look at the official readme.txt

banti-album-proofing/banti-album-proofing.php 92% from 13 tests

The main file in "Banti Album Proofing" v. 1.2.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Description: The description should be shorter than 140 characters (currently 292 characters long)

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 detected206 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP33453180
JavaScript10026

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.24
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%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
4 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/add-new-page.png5.01KB4.18KB▼ 16.49%
js/images/icon-16.png1.58KB0.62KB▼ 60.66%
images/icon-18.png1.74KB0.88KB▼ 49.83%
images/add-banti-editor.png2.63KB1.78KB▼ 32.24%