84% network-database-search

Code Review | Network Database Search

WordPress plugin Network Database Search scored84%from 54 tests.

About plugin

  • Plugin page: network-database-...
  • Plugin version: 0.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Oct 8, 2017
  • Latest release: Oct 9, 2017
  • Number of updates: 8
  • Update frequency: every 1.9 days
  • Top authors: micahjm (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /681 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▼0.58MB] [CPU: ▼18.48ms] Passed 4 tests

Server-side resources used by Network Database Search
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1137.51 ▼1.45
Dashboard /wp-admin3.40 ▲0.1044.07 ▼6.77
Posts /wp-admin/edit.php3.52 ▲0.1645.51 ▼5.75
Add New Post /wp-admin/post-new.php3.28 ▼2.6135.96 ▼58.97
Media Library /wp-admin/upload.php3.32 ▲0.1034.47 ▼2.43
Database Search /wp-admin/tools.php?page=network-database-search3.2932.24

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

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

Browser metrics Passed 4 tests

Network Database Search: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲6913.66 ▼0.731.60 ▼0.0742.35 ▲3.34
Dashboard /wp-admin2,207 ▲165.82 ▼0.0899.99 ▼15.1239.82 ▼13.56
Posts /wp-admin/edit.php2,096 ▲71.99 ▼0.0439.50 ▲3.2635.49 ▲2.72
Add New Post /wp-admin/post-new.php1,536 ▲1723.29 ▲0.10660.43 ▼34.9058.68 ▼5.22
Media Library /wp-admin/upload.php1,395 ▲74.19 ▼0.0595.40 ▼4.0444.87 ▲0.42
Database Search /wp-admin/tools.php?page=network-database-search8551.9237.3131.59

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget

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 everything seems fine, this is not 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
  • 12× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/network-database-search/result-filters/add-titles.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/network-database-search/result-filters/group-results/group-children-with-parents.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/network-database-search/query-types/gravity-forms.php:19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/network-database-search/result-filters/clip-long-fields.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/network-database-search/query-types/core.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/network-database-search/api/get-rest-api-url.php:19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/network-database-search/api/search-site.php:67
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/network-database-search/result-filters/group-results/get-missing-parents.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/network-database-search/result-filters/add-edit-links.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/network-database-search/api/get-query-types.php:15

User-side errors Passed 1 test

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

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 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
7 plugin tags: options, network, custom fields, multisite, menus...

network-database-search/network-database-search.php Passed 13 tests

The main PHP file in "Network Database Search" ver. 0.1 adds more information about the plugin and also serves as the entry point for this plugin
140 characters long description:
Powerful multisite database search for WordPress administrators. Search posts, custom fields, menus, media, options, and even Gravity Forms.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected1,343 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript1184100640
PHP12136178542
LESS23211160
CSS1091

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.26
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%
Functions50
▷ Named functions3366.00%
▷ Anonymous functions1734.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin