10% tayori

Code Review | Tayori Form Plugin

WordPress plugin Tayori Form Plugin scored 10% from 54 tests.

About plugin

  • Plugin page: tayori
  • Plugin version: 1.2.9
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.9.8
  • WordPress version: 6.3.1
  • First release: Nov 4, 2015
  • Latest release: Aug 29, 2018
  • Number of updates: 38
  • Update frequency: every 27.2 days
  • Top authors: tayoricom (100%)

Code review

54 tests

User reviews

1 review

Install metrics

400+ active / 6,789 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The following installer errors require your attention
  • This plugin did not install gracefully
    • > Notice in wp-content/plugins/tayori/includes/tayori.php+59
    Undefined variable: tayori_db_version

Server metrics [RAM: ▼1.12MB] [CPU: ▼37.67ms] Passed 4 tests

An overview of server-side resources used by Tayori Form Plugin
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.08 ▼1.395.07 ▼36.91
Dashboard /wp-admin3.15 ▼0.1626.44 ▼26.16
Posts /wp-admin/edit.php3.15 ▼0.2128.63 ▼22.64
Add New Post /wp-admin/post-new.php3.15 ▼2.7425.56 ▼64.95
Media Library /wp-admin/upload.php3.15 ▼0.0826.91 ▼8.64
Mail Setting /wp-admin/admin.php?page=tayori-mail-setting3.1531.39
Tayori /wp-admin/admin.php?page=tayori/admin/admin.php3.1529.10

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 123 new files
Database: 1 new table, 7 new options
New tables
wp_tayori
New WordPress options
widget_recent-comments
widget_recent-posts
db_upgraded
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
tayori_db_version

Browser metrics Passed 4 tests

Checking browser requirements for Tayori Form Plugin
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,208 ▲38317.21 ▲3.9835.32 ▲33.2248.66 ▲3.93
Dashboard /wp-admin2,233 ▲274.86 ▼0.01114.00 ▲0.0245.25 ▼0.48
Posts /wp-admin/edit.php2,119 ▲301.97 ▼0.0737.69 ▼3.9334.76 ▼3.36
Add New Post /wp-admin/post-new.php1,536 ▼617.81 ▼0.56706.40 ▲52.5363.23 ▲5.26
Media Library /wp-admin/upload.php1,409 ▲244.23 ▲0.0396.78 ▼6.4241.25 ▼2.46
Mail Setting /wp-admin/admin.php?page=tayori-mail-setting8641.9229.6379.51
Tayori /wp-admin/admin.php?page=tayori/admin/admin.php2,1142.1939.90105.36

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Uninstall procedure validation failed for this plugin
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These errors were triggered by the plugin
  • 14 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=tayori/admin/admin.php
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
  • 8 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=tayori/admin/admin.php
    • > Notice in wp-content/plugins/tayori/admin/admin.php+659
    Undefined variable: validate_data

SRP 0% 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
  • 4× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/tayori/form.php
    • > /wp-content/plugins/tayori/includes/form_chat_sp.php
    • > /wp-content/plugins/tayori/includes/form.php
    • > /wp-content/plugins/tayori/includes/form_chat_pc.php
  • 10× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Notice
      Undefined index: HTTP_ACCEPT_LANGUAGE in wp-content/plugins/tayori/includes/language.php on line 2
    • > PHP Notice
      Undefined index: HTTP_ACCEPT_LANGUAGE in wp-content/plugins/tayori/includes/language.php on line 2
    • > PHP Notice
      Undefined index: HTTP_ACCEPT_LANGUAGE in wp-content/plugins/tayori/includes/language.php on line 2
    • > PHP Warning
      Use of undefined constant TAYORI_PLUGIN_DIR - assumed 'TAYORI_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/tayori/settings.php on line 3
    • > PHP Warning
      require_once(TAYORI_PLUGIN_DIR/includes/functions.php): failed to open stream: No such file or directory in wp-content/plugins/tayori/settings.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function load_plugin_textdomain() in wp-content/plugins/tayori/admin/admin.php:3
    • > PHP Fatal error
      require_once(): Failed opening required 'TAYORI_PLUGIN_DIR/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/tayori/settings.php on line 3
    • > PHP Notice
      Undefined index: HTTP_REFERER in wp-content/plugins/tayori/includes/sendmail.php on line 3
    • > PHP Notice
      Undefined index: HTTP_ACCEPT_LANGUAGE in wp-content/plugins/tayori/includes/language.php on line 2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/tayori/form.php:325

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need your attention:
  • Screenshots: Please add an image for screenshot #1 (Tayori button configuration menu.)
You can take inspiration from this readme.txt

tayori/tayori.php Passed 13 tests

Analyzing the main PHP file in "Tayori Form Plugin" version 1.2.9
33 characters long description:
Tayori Form Plugin For WordPress.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin28,517 lines of code in 28 files:
LanguageFilesBlank linesComment linesLines of code
CSS12,80718321,319
PHP13247324,591
JavaScript71013222,385
PO File17386153
SVG30242
XML20026
JSON1001

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.66
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity2.20
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods480.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants12
▷ Global constants12100.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
84 PNG files occupy 0.22MB with 0.12MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/29.png2.24KB1.20KB▼ 46.27%
images/simple-button-icon.png1.27KB0.63KB▼ 50.42%
images/35.png2.63KB1.49KB▼ 43.27%
images/thumb_sp_pop_1.png2.18KB0.70KB▼ 67.79%
images/icn_gray.png1.24KB0.37KB▼ 70.38%