89% ymc-crossword

Code Review | YMC Crossword

WordPress plugin YMC Crossword scored89%from 54 tests.

About plugin

  • Plugin page: ymc-crossword
  • Plugin version: 2.1
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-6.4
  • WordPress version: 6.3.1
  • First release: Mar 10, 2023
  • Latest release: Nov 4, 2023
  • Number of updates: 9
  • Update frequency: every 26.6 days
  • Top authors: wssoffice21 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

70+ active /615 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 gracefully, with no errors

Server metrics [RAM: ▲0.20MB] [CPU: ▼2.04ms] Passed 4 tests

Analyzing server-side resources used by YMC Crossword
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.67 ▲0.2042.98 ▲1.72
Dashboard /wp-admin3.50 ▲0.2046.00 ▼3.21
Posts /wp-admin/edit.php3.61 ▲0.2647.93 ▲5.15
Add New Post /wp-admin/post-new.php6.11 ▲0.2286.03 ▼9.75
Media Library /wp-admin/upload.php3.42 ▲0.2035.75 ▲3.09
Crossword /wp-admin/edit.php?post_type=ymc_crossword3.4734.99
Add New /wp-admin/post-new.php?post_type=ymc_crossword3.5543.28

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 40 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for YMC Crossword
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,923 ▲16113.52 ▼0.6910.06 ▲8.2044.76 ▲1.97
Dashboard /wp-admin2,240 ▲595.82 ▲0.1191.47 ▼11.7837.53 ▼5.49
Posts /wp-admin/edit.php2,147 ▲442.24 ▲0.2641.95 ▲0.4737.96 ▼0.68
Add New Post /wp-admin/post-new.php1,565 ▲3923.33 ▲0.04590.71 ▼62.7532.47 ▼24.49
Media Library /wp-admin/upload.php1,448 ▲484.42 ▲0.2299.88 ▼2.3043.08 ▼0.80
Crossword /wp-admin/edit.php?post_type=ymc_crossword1,1082.2234.8228.52
Add New /wp-admin/post-new.php?post_type=ymc_crossword3,2468.01226.73104.43

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP Passed 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 SRP test was a success

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 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
4 plugin tags: crossword, game, mind, puzzles

ymc-crossword/ymc-crossword.php 85% from 13 tests

Analyzing the main PHP file in "YMC Crossword" version 2.1
Please take the time to fix the following:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Domain Path: The domain path points to an invalid folder, "/languages" does not exist

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin2,539 lines of code in 24 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript319871962
PHP9266175772
Sass24718741
SVG83262
CSS2222

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity9.86
▷ Minimum class complexity1.00
▷ Maximum class complexity38.00
Average method complexity2.79
▷ Minimum method complexity1.00
▷ Maximum method complexity32.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods35
▷ Static methods25.71%
▷ Public methods3291.43%
▷ Protected methods00.00%
▷ Private methods38.57%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants4
▷ Global constants375.00%
▷ Class constants125.00%
▷ Public constants1100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 1.48MB with 1.21MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
YmcCrossword/assets/images/bg_popup.png1,509.29KB313.50KB▼ 79.23%
YmcCrossword/assets/images/logo.png4.88KB0.78KB▼ 84.05%