83% instant-search-suggest

Code Review | Instant Search & Suggest

WordPress plugin Instant Search & Suggest scored83%from 54 tests.

About plugin

  • Plugin page: instant-search-su...
  • Plugin version: 2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.3
  • WordPress version: 6.3.1
  • First release: Mar 12, 2015
  • Latest release: Jul 7, 2015
  • Number of updates: 4
  • Update frequency: every 30.7 days
  • Top authors: scottsweb (100%)

Code review

54 tests

User reviews

12 reviews

Install metrics

500+ active /10,668 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼2.19ms] Passed 4 tests

Analyzing server-side resources used by Instant Search & Suggest
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0735.87 ▼4.66
Dashboard /wp-admin3.37 ▲0.0746.07 ▼6.18
Posts /wp-admin/edit.php3.42 ▲0.0751.66 ▲4.61
Add New Post /wp-admin/post-new.php5.95 ▲0.0794.10 ▲3.48
Media Library /wp-admin/upload.php3.29 ▲0.0733.33 ▼1.40
Instant Search /wp-admin/options-general.php?page=iss-settings3.2631.43

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 16 new files
Database: no new tables, 7 new options
New WordPress options
wpiss_options
can_compress_scripts
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Instant Search & Suggest
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,937 ▲20213.87 ▼0.699.09 ▲7.1639.18 ▼13.65
Dashboard /wp-admin2,210 ▲224.85 ▼1.03112.29 ▼4.1442.32 ▼0.52
Posts /wp-admin/edit.php2,096 ▲72.02 ▼0.0239.54 ▲2.9536.86 ▲1.42
Add New Post /wp-admin/post-new.php1,532 ▼218.72 ▼4.55618.83 ▼78.8455.07 ▲0.03
Media Library /wp-admin/upload.php1,392 ▲74.24 ▲0.0395.26 ▼15.7242.91 ▼0.65
Instant Search /wp-admin/options-general.php?page=iss-settings9572.0623.5627.82

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

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
The following issues need your attention
  • 4× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/instant-search-suggest/assets/inc/iss-ajax.php:43
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/instant-search-suggest/assets/inc/iss-admin.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/instant-search-suggest/assets/inc/iss-theme.php:33
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/instant-search-suggest/iss.php:27

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that need to be fixed:
  • Tags: You are using too many tags: 13 tag instead of maximum 10
The official readme.txt is a good inspiration

instant-search-suggest/iss.php 85% from 13 tests

Analyzing the main PHP file in "Instant Search & Suggest" version 2.1
The following require your attention:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("instant-search-suggest.php" instead of "iss.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 plugin4,315 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PHP61402,1514,028
JavaScript3341288
CSS1201378
PO File1232761
Markdown134045
JSON10015

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.59
Average class complexity72.08
▷ Minimum class complexity1.00
▷ Maximum class complexity555.00
Average method complexity4.53
▷ Minimum method complexity1.00
▷ Maximum method complexity59.00
Code structure
Namespaces0
Interfaces1
Traits0
Classes12
▷ Abstract classes216.67%
▷ Concrete classes1083.33%
▷ Final classes00.00%
Methods264
▷ Static methods7327.65%
▷ Public methods21982.95%
▷ Protected methods4316.29%
▷ Private methods20.76%
Functions23
▷ Named functions23100.00%
▷ Anonymous functions00.00%
Constants10
▷ Global constants10100.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
PNG images were not found in this plugin