10% innoleads

Code Review | InnoLeads

WordPress plugin InnoLeads scored10%from 54 tests.

About plugin

  • Plugin page: innoleads
  • Plugin version: 0.2.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.1.8
  • WordPress version: 6.3.1
  • First release: Feb 28, 2016
  • Latest release: Apr 27, 2016
  • Number of updates: 22
  • Update frequency: every 2.6 days
  • Top authors: KA50 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /524 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Please fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Notice in wp-content/plugins/innoleads/knox.php+16
    Undefined variable: wp_version

Server metrics [RAM: ▼0.92MB] [CPU: ▼37.32ms] Passed 4 tests

This is a short check of server-side resources used by InnoLeads
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0348.22 ▲3.77
Dashboard /wp-admin3.02 ▼0.2826.91 ▼29.41
Posts /wp-admin/edit.php3.02 ▼0.3429.61 ▼21.45
Add New Post /wp-admin/post-new.php3.02 ▼2.8729.11 ▼81.39
Media Library /wp-admin/upload.php3.02 ▼0.2122.62 ▼17.04

Server storage [IO: ▲2.23MB] [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: 31 new files
Database: no new tables, 7 new options
New WordPress options
knox_device_id
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for InnoLeads
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,889 ▲12813.89 ▼0.471.55 ▼0.6326.63 ▼13.35
Dashboard /wp-admin2,280 ▲1005.67 ▲0.04114.95 ▲19.9786.48 ▲44.40
Posts /wp-admin/edit.php2,118 ▲151.99 ▲0.0336.54 ▼1.9031.97 ▼0.93
Add New Post /wp-admin/post-new.php1,569 ▲4318.21 ▼4.96659.26 ▲42.1362.30 ▲7.57
Media Library /wp-admin/upload.php1,412 ▲94.21 ▼0.01100.39 ▲1.2766.27 ▲22.24

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
These items require your attention
  • This plugin did not uninstall without warnings or errors
    • > Warning in wp-content/plugins/innoleads/knox.php+100
    Use of undefined constant knox_plugin - assumed 'knox_plugin' (this will throw an Error in a future version of PHP)
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-comments
    • knox_device_id
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 75% 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 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
Please fix the following
  • 4× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/innoleads/admin_page.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/innoleads/functions.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/innoleads/dashboard.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/innoleads/knox.php:10

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (First step.), #2 (Second step.), #3 (Finished!)
The official readme.txt might help

innoleads/knox.php 92% from 13 tests

This is the main PHP file of "InnoLeads" version 0.2.3, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
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 ("innoleads.php" instead of "knox.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Good job! No executable or dangerous file extensions detected13,187 lines of code in 21 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript52,69116,46012,101
XML900670
PHP55324236
CSS2340180

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.09
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%
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

PNG files should be compressed to save space and minimize bandwidth usage
4 PNG files occupy 0.21MB with 0.10MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/logo.png106.37KB64.59KB▼ 39.27%
images/innoleads_icon.png81.79KB33.77KB▼ 58.71%
images/white_icon.png26.50KB12.31KB▼ 53.56%
images/icon.png2.08KB1.21KB▼ 41.67%