78% the-voice-designer-by-data-driven-design

Code Review | The Voice Designer

WordPress plugin The Voice Designer scored 78% from 54 tests.

About plugin

  • Plugin page: the-voice-designe...
  • Plugin version: 0.3.1
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.1-5.7
  • WordPress version: 6.3.1
  • First release: Jan 7, 2020
  • Latest release: Mar 10, 2021
  • Number of updates: 21
  • Update frequency: every 20.6 days
  • Top authors: dddjoe (76.19%)devdatadrivendesign (28.57%)

Code review

54 tests

User reviews

1 review

Install metrics

50+ active / 1,307 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
Install script ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼6.30ms] Passed 4 tests

An overview of server-side resources used by The Voice Designer
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0339.04 ▼1.82
Dashboard /wp-admin3.34 ▲0.0448.38 ▲0.52
Posts /wp-admin/edit.php3.46 ▲0.1073.32 ▲22.51
Add New Post /wp-admin/post-new.php5.86 ▼0.0279.37 ▼22.95
Media Library /wp-admin/upload.php3.25 ▲0.0231.44 ▼0.94

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 66 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
ddd-voice-site-guid
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for The Voice Designer
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,975 ▲24014.95 ▲0.691.97 ▲0.2146.21 ▲0.09
Dashboard /wp-admin2,339 ▲1486.40 ▲1.50133.14 ▲33.9890.30 ▲46.30
Posts /wp-admin/edit.php2,257 ▲1683.57 ▲1.5349.82 ▲9.3765.47 ▲27.68
Add New Post /wp-admin/post-new.php1,556 ▲1418.89 ▲0.47641.62 ▲3.1232.70 ▼21.78
Media Library /wp-admin/upload.php1,399 ▲174.00 ▼0.2084.27 ▼16.3375.01 ▲29.25

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • ddd-voice-site-guid

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
  • 3× PHP files output text when accessed directly:
    • > /wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/examples/showclix.php
    • > /wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/tests/bootstrap-server.php
    • > /wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/examples/github.php
  • 26× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/examples/showclix.php on line 24
    • > PHP Warning
      Use of undefined constant WEB_SERVER_PORT - assumed 'WEB_SERVER_PORT' (this will throw an Error in a future version of PHP) in wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/tests/bootstrap-server.php on line 34
    • > PHP Notice
      Trying to get property 'name' of non-object in wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/examples/github.php on line 9
    • > PHP Fatal error
      Uncaught Error: Class 'Httpful\\Handlers\\MimeHandlerAdapter' not found in wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/src/Httpful/Handlers/XmlHandler.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'Httpful\\Handlers\\MimeHandlerAdapter' not found in wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/src/Httpful/Handlers/CsvHandler.php:9
    • > PHP Notice
      Trying to get property 'event_start' of non-object in wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/examples/showclix.php on line 14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/the-voice-designer-by-data-driven-design/wp/editor-sidebar.php:26
    • > PHP Warning
      Use of undefined constant WEB_SERVER_PORT - assumed 'WEB_SERVER_PORT' (this will throw an Error in a future version of PHP) in wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/tests/Httpful/HttpfulTest.php on line 22
    • > PHP Warning
      Use of undefined constant WEB_SERVER_DOCROOT - assumed 'WEB_SERVER_DOCROOT' (this will throw an Error in a future version of PHP) in wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/tests/bootstrap-server.php on line 15
    • > PHP Notice
      Trying to get property 'created-at' of non-object in wp-content/plugins/the-voice-designer-by-data-driven-design/vendor/nategood/httpful/examples/github.php on line 9

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
4 plugin tags: voice, alexa, google actions, alexa skills

the-voice-designer-by-data-driven-design/voice-plugin.php 92% from 13 tests

The main PHP file in "The Voice Designer" ver. 0.3.1 adds more information about the plugin and also serves as the entry point for this plugin
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("the-voice-designer-by-data-driven-design.php" instead of "voice-plugin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected2,799 lines of code in 53 files:
LanguageFilesBlank linesComment linesLines of code
PHP435371,0612,426
Markdown2910181
JSON40092
JavaScript16068
XML11015
YAML13014
CSS1003

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity7.31
▷ Minimum class complexity1.00
▷ Maximum class complexity76.00
Average method complexity1.88
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
Namespaces8
Interfaces0
Traits0
Classes32
▷ Abstract classes13.12%
▷ Concrete classes3196.88%
▷ Final classes13.23%
Methods232
▷ Static methods5222.41%
▷ Public methods21693.10%
▷ Protected methods10.43%
▷ Private methods156.47%
Functions22
▷ Named functions836.36%
▷ Anonymous functions1463.64%
Constants46
▷ Global constants48.70%
▷ Class constants4291.30%
▷ Public constants4095.24%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
7 PNG files occupy 0.90MB with 0.52MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/icon-256x256.png46.86KB17.75KB▼ 62.12%
wp/logo.png35.47KB13.67KB▼ 61.46%
assets/screenshot-1.png797.00KB229.62KB▼ 71.19%
wp/logo-icon-lg.png6.90KB3.03KB▼ 56.06%
wp/logo-icon.png1.77KB1.10KB▼ 38.07%