78% pataa-address-autofill

Code Review | Address Autofill - The Plugin helps the customers to auto-fill their address

WordPress plugin Address Autofill - The Plugin helps the customers to auto-fill their address scored78%from 54 tests.

About plugin

  • Plugin page: pataa-address-aut...
  • Plugin version: 1.0.3
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.2
  • WordPress version: 6.3.1
  • First release: Dec 1, 2022
  • Latest release: May 18, 2023
  • Number of updates: 15
  • Update frequency: every 11.6 days
  • Top authors: pataa5 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /263 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼4.48ms] Passed 4 tests

Analyzing server-side resources used by Address Autofill - The Plugin helps the customers to auto-fill their address
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1044.88 ▲8.38
Dashboard /wp-admin3.34 ▼0.0149.87 ▼7.64
Posts /wp-admin/edit.php3.39 ▲0.0344.47 ▼0.06
Add New Post /wp-admin/post-new.php5.94 ▲0.0584.16 ▼12.75
Media Library /wp-admin/upload.php3.26 ▲0.0334.83 ▲2.55

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Address Autofill - The Plugin helps the customers to auto-fill their address
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,304 ▲55819.01 ▲4.7351.83 ▲50.0942.98 ▲0.70
Dashboard /wp-admin2,219 ▲314.86 ▼1.02112.72 ▲5.6543.72 ▼2.26
Posts /wp-admin/edit.php2,105 ▲162.01 ▼0.0035.99 ▲0.7331.59 ▼3.86
Add New Post /wp-admin/post-new.php1,538 ▲1818.18 ▼5.14627.07 ▼32.4957.20 ▲10.47
Media Library /wp-admin/upload.php1,407 ▲194.22 ▼0.08100.39 ▲6.1042.26 ▲1.25

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP 0% 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 take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/pataa-address-autofill/public/partials/addressautofill-public-display.php
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/pataa-address-autofill/admin/partials/addressautofill-admin-settings-display.php:82

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 93% 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
3 plugin tags: autofill, address, woocommerce

pataa-address-autofill/addressautofill.php 85% from 13 tests

"Address Autofill - The Plugin helps the customers to auto-fill their address" version 1.0.3's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("pataa-address-autofill.php" instead of "addressautofill.php")
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug

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
No dangerous file extensions were detected2,879 lines of code in 23 files:
LanguageFilesBlank linesComment linesLines of code
PHP122215861,036
CSS290221,021
JavaScript413988792
SVG50030

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.13
Average class complexity6.71
▷ Minimum class complexity1.00
▷ Maximum class complexity27.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods40
▷ Static methods410.00%
▷ Public methods3485.00%
▷ Protected methods00.00%
▷ Private methods615.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
6 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/img/icons/view.png0.52KB0.48KB▼ 8.19%
admin/img/icons/exit-top-right.png15.81KB4.45KB▼ 71.85%
admin/img/icons/eye.png20.03KB7.23KB▼ 63.91%
admin/img/pataa-icn.png3.45KB1.45KB▼ 57.96%
admin/img/icons/hidden.png0.68KB0.76KB0.00%