68% keyword-collector

Code Review | KeyWord Collector

WordPress plugin KeyWord Collector scored 68% from 54 tests.

About plugin

  • Plugin page: keyword-collector
  • Plugin version: 1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.7.3
  • WordPress version: 6.3.1
  • First release: Apr 24, 2017
  • Latest release: Aug 18, 2017
  • Number of updates: 19
  • Update frequency: every 6.4 days
  • Top authors: adsimple (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 2,235 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼1.94MB] [CPU: ▼53.16ms] Passed 4 tests

An overview of server-side resources used by KeyWord Collector
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.04 ▼1.427.08 ▼36.96
Dashboard /wp-admin2.06 ▼1.2411.65 ▼36.14
Posts /wp-admin/edit.php2.06 ▼1.297.96 ▼42.71
Add New Post /wp-admin/post-new.php2.06 ▼3.827.07 ▼96.83
Media Library /wp-admin/upload.php2.06 ▼1.167.56 ▼25.15
KeyWord Collector /wp-admin/options-general.php?page=wp-keyword2.067.98

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 7 new files
Database: no new tables, 14 new options
New WordPress options
auto_insert_firma
before_items
delete_interval
theysaidso_admin_options
after_items
update_interval
after_list
widget_theysaidso_widget
num
db_upgraded
...

Browser metrics Passed 4 tests

A check of browser resources used by KeyWord Collector
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,914 ▲17913.67 ▼0.925.40 ▲3.5041.63 ▲2.55
Dashboard /wp-admin2,233 ▲454.90 ▲0.04108.71 ▲4.6138.38 ▼5.64
Posts /wp-admin/edit.php2,119 ▲302.07 ▲0.0540.63 ▼0.7737.00 ▲1.50
Add New Post /wp-admin/post-new.php1,551 ▲923.24 ▲5.11632.44 ▲12.2452.70 ▼1.86
Media Library /wp-admin/upload.php1,409 ▲244.23 ▲0.0697.36 ▼8.6542.85 ▼1.86
KeyWord Collector /wp-admin/options-general.php?page=wp-keyword1,0182.2126.6639.23

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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
  • Uninstall procedure validation failed for this plugin
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the WPKeyWordJS handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These server-side errors were triggered
    • > GET request to /wp-admin/options-general.php?page=wp-keyword
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the WPKeyWordJS handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
    • > GET request to /wp-admin/options-general.php?page=wp-keyword
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the WPKeyWordCSS handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)

SRP 50% 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 trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/keyword-collector/wp_keyword.php:29

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
4 plugin tags: shortcode, keyword, tag, autoinsert

keyword-collector/wp_keyword.php 92% from 13 tests

The main file in "KeyWord Collector" v. 1.4 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("keyword-collector.php" instead of "wp_keyword.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin860 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP353134751
CSS10076
JavaScript12033

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity18.50
▷ Minimum class complexity9.00
▷ Maximum class complexity28.00
Average method complexity4.18
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods11
▷ Static methods00.00%
▷ Public methods11100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.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