71% anyguide

Code Review | AnyRoad

WordPress plugin AnyRoad scored71%from 54 tests.

About plugin

  • Plugin page: anyguide
  • Plugin version: 1.3.2
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-4.7.3
  • WordPress version: 6.3.1
  • First release: Jul 10, 2015
  • Latest release: Mar 14, 2017
  • Number of updates: 25
  • Update frequency: every 24.5 days
  • Top authors: anyguide (100%)

Code review

54 tests

User reviews

9 reviews

Install metrics

30+ active /3,989 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
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.16MB] [CPU: ▼19.28ms] Passed 4 tests

Server-side resources used by AnyRoad
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0839.75 ▼0.93
Dashboard /wp-admin3.13 ▼0.1726.40 ▼21.96
Posts /wp-admin/edit.php3.27 ▼0.0931.79 ▼14.31
Add New Post /wp-admin/post-new.php5.51 ▼0.3865.41 ▼29.81
Media Library /wp-admin/upload.php3.22 ▼0.0126.38 ▼11.03
Help /wp-admin/admin.php?page=anyguide-help3.2932.65
My Snippets /wp-admin/admin.php?page=anyguide-manage3.3134.44
Settings /wp-admin/admin.php?page=anyguide-settings3.2929.25

Server storage [IO: ▲3.30MB] [DB: ▲0.07MB] Passed 3 tests

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 62 new files
Database: 1 new table, 7 new options
New tables
wp_anyguide_short_code
New WordPress options
widget_recent-posts
widget_theysaidso_widget
db_upgraded
can_compress_scripts
anyguide_limit
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by AnyRoad
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,850 ▲6414.37 ▲0.092.94 ▲1.1242.24 ▼1.71
Dashboard /wp-admin2,230 ▲535.69 ▲0.0885.27 ▼5.2267.64 ▲31.22
Posts /wp-admin/edit.php2,129 ▲321.99 ▼0.0234.56 ▼1.4931.47 ▼2.96
Add New Post /wp-admin/post-new.php1,571 ▲3322.98 ▼0.32663.11 ▼6.49140.05 ▲87.20
Media Library /wp-admin/upload.php1,432 ▲324.11 ▼0.11102.18 ▼6.6175.47 ▲32.05
Help /wp-admin/admin.php?page=anyguide-help9985.25157.6365.68
My Snippets /wp-admin/admin.php?page=anyguide-manage1,0355.35167.5763.49
Settings /wp-admin/admin.php?page=anyguide-settings9625.1496.6627.97

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 25% 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 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/anyguide/admin/footer.php
    • > /wp-content/plugins/anyguide/admin/help.php
  • 16× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function stripslashes_deep() in wp-content/plugins/anyguide/admin/snippets.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_currentuserinfo() in wp-content/plugins/anyguide/admin/snippet-edit.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/anyguide/ag-functions.php:40
    • > PHP Fatal error
      Uncaught Error: Call to undefined function stripslashes_deep() in wp-content/plugins/anyguide/admin/snippet-delete.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/anyguide/ag-functions.php:40
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/anyguide/shortcode-handler.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function stripslashes_deep() in wp-content/plugins/anyguide/admin/snippet-add.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/anyguide/shortcode_tynimce.php:38
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/anyguide/admin/menu.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_uninstall_hook() in wp-content/plugins/anyguide/admin/uninstall.php:30

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
These are user-side errors you should fix
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=anyguide-settings
    • > Network (severe)
    https://api-iam.intercom.io/messenger/web/ping - Failed to load resource: the server responded with a status of 403 ()

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 81% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes:
  • Contributors: The plugin contributors field is not present
  • Screenshots: Add a description for screenshot #2 in anyguide/assets to your readme.txt
  • Tags: Please delete some tags, you are using 13 tag instead of maximum 10
The official readme.txt might help

anyguide/anyguide.php 92% from 13 tests

"AnyRoad" version 1.3.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected11,453 lines of code in 32 files:
LanguageFilesBlank linesComment linesLines of code
CSS6219449,702
PHP1818659967
SVG201594
JavaScript66121190

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity5.00
▷ Minimum class complexity5.00
▷ Maximum class complexity5.00
Average method complexity2.33
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions30
▷ Named functions30100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
17 PNG files occupy 1.67MB with 0.64MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-3.png388.82KB160.75KB▼ 58.66%
assets/images/delete.png3.59KB2.18KB▼ 39.36%
assets/images/button16.png14.75KB0.77KB▼ 94.77%
assets/images/facebook.png0.59KB0.66KB0.00%
assets/images/logo.png0.51KB0.53KB0.00%