10% autofastindex

Code Review | AutoFastindex

WordPress plugin AutoFastindex scored10%from 54 tests.

About plugin

  • Plugin page: autofastindex
  • Plugin version: 2.10.7
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.8
  • WordPress version: 6.3.1
  • First release: Jul 26, 2021
  • Latest release: Mar 20, 2023
  • Number of updates: 38
  • Update frequency: every 15.9 days
  • Top authors: kumarshubhendu228 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

300+ active /4,077 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
These installer errors require your attention
  • Install procedure had errors
    • > Warning in wp-content/plugins/autofastindex/inc/main.php+4
    file_get_contents(wp-content/uploads/autoindex_do_not_delete_this_file/notification.json): failed to open stream: No such file or directory

Server metrics [RAM: ▼1.93MB] [CPU: ▼50.41ms] Passed 4 tests

A check of server-side resources used by AutoFastindex
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.06 ▼1.404.40 ▼35.00
Dashboard /wp-admin2.08 ▼1.265.53 ▼49.16
Posts /wp-admin/edit.php2.08 ▼1.276.55 ▼37.90
Add New Post /wp-admin/post-new.php2.08 ▼3.805.40 ▼79.59
Media Library /wp-admin/upload.php2.08 ▼1.145.26 ▼26.77
AutoFast /wp-admin/admin.php?page=AutoFastindex2.085.86
Lisense /wp-admin/admin.php?page=lisense2.087.57
Notices /wp-admin/admin.php?page=notice2.086.09
Manual Indexing /wp-admin/admin.php?page=Manual_Indexing2.085.64
Success Logs /wp-admin/admin.php?page=successlogs2.085.35

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 21 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for AutoFastindex
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,967 ▲20614.43 ▲0.081.93 ▲0.2837.67 ▼1.45
Dashboard /wp-admin2,376 ▲2046.15 ▲0.49119.49 ▲14.1840.74 ▲2.68
Posts /wp-admin/edit.php2,304 ▲2073.50 ▲1.5247.01 ▲12.5230.40 ▼7.58
Add New Post /wp-admin/post-new.php1,559 ▲3123.43 ▲0.39576.77 ▼60.7131.85 ▼17.60
Media Library /wp-admin/upload.php1,444 ▲444.17 ▼0.0382.75 ▼12.3142.10 ▼2.83
AutoFast /wp-admin/admin.php?page=AutoFastindex3,10123.68659.15106.60
Lisense /wp-admin/admin.php?page=lisense7291.5011.6929.76
Notices /wp-admin/admin.php?page=notice7261.5011.6421.65
Manual Indexing /wp-admin/admin.php?page=Manual_Indexing7291.689.7817.08
Success Logs /wp-admin/admin.php?page=successlogs7271.5011.7422.18

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • This plugin cannot be uninstalled
    • > Warning in wp-content/plugins/autofastindex/inc/main.php+4
    file_get_contents(wp-content/uploads/autoindex_do_not_delete_this_file/notification.json): failed to open stream: No such file or directory
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 0% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Please fix the following server-side errors
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=successlogs
    • > Warning in wp-content/plugins/autofastindex/inc/main.php+4
    file_get_contents(wp-content/uploads/autoindex_do_not_delete_this_file/notification.json): failed to open stream: No such file or directory
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=successlogs
    • > Notice in wp-content/plugins/autofastindex/inc/main.php+8
    Trying to get property 'request_notify' of non-object
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+270
    Undefined variable: email
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+278
    Undefined variable: site
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+297
    Undefined variable: e_notification
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+310
    Undefined variable: w_notification
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+322
    Undefined variable: whatsapp_no
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+664
    Undefined variable: enabledirectIndexing
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+646
    Undefined variable: enablegoogle
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+412
    Undefined variable: file
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+435
    Undefined variable: google_text
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+638
    Undefined variable: enablebing
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+503
    Undefined variable: bingapi
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+654
    Undefined variable: enable_yandex
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+565
    Undefined variable: yandex_UserId
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+573
    Undefined variable: yandex_HostId
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+581
    Undefined variable: yandex_AuthKey
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Notice in wp-content/plugins/autofastindex/inc/setting.php+724
    Undefined variable: google_text_enable

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/autofastindex/Autoindex.php
  • 15× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Warning
      Use of undefined constant autoindex_upload - assumed 'autoindex_upload' (this will throw an Error in a future version of PHP) in wp-content/plugins/autofastindex/inc/autoindex.php on line 6
    • > PHP Notice
      Trying to get property 'url' of non-object in wp-content/plugins/autofastindex/inc/autoindex.php on line 8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_enqueue_script() in wp-content/plugins/autofastindex/inc/lisense.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_enqueue_script() in wp-content/plugins/autofastindex/inc/success.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_enqueue_script() in wp-content/plugins/autofastindex/inc/manualIndex.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_enqueue_script() in wp-content/plugins/autofastindex/inc/setting.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/autofastindex/inc/error.php:47
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_permalink() in wp-content/plugins/autofastindex/inc/autoindex.php:14
    • > PHP Notice
      Trying to get property 'google_json_file' of non-object in wp-content/plugins/autofastindex/inc/autoindex.php on line 11
    • > PHP Notice
      Trying to get property 'email' of non-object in wp-content/plugins/autofastindex/inc/autoindex.php on line 12

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
These are user-side errors you should fix
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=successlogs
    • > Network (severe)
    wp-content/plugins/autofastindex/media-uploader.js?ver=6.3.1 - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1 1:28609 "jQuery.Deferred exception: $j(...).accordion is not a function" "TypeError: $j(...).accordion is not a function\n at HTMLDocument.\u003Canonymous> (/wp-admin/admin.php?page=AutoFastindex:635:24)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1:2:27292)" undefined
    • > GET request to /wp-admin/admin.php?page=AutoFastindex
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1 1:28721 Uncaught TypeError: $j(...).accordion is not a function

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 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
These attributes need your attention:
  • Plugin Name: Please specify the plugin name on the first line ( === autofastindex === )
You can look at the official readme.txt

autofastindex/Autoindex.php 85% from 13 tests

The main PHP file in "AutoFastindex" ver. 2.10.7 adds more information about the plugin and also serves as the entry point for this plugin
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("autofastindex.php" instead of "Autoindex.php")
  • Description: The description should be shorter than 140 characters (currently 232 characters long)

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 detected1,537 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
PHP11670161,302
JavaScript1311170
Markdown123053
JSON1009
CSS3093

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
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%
Functions16
▷ Named functions1593.75%
▷ Anonymous functions16.25%
Constants1
▷ Global constants1100.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
2 PNG files occupy 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/email.png29.85KB11.36KB▼ 61.93%
assets/images/whatsapp.png22.33KB9.31KB▼ 58.30%