84% sudoku-game

Code Review | Sudoku - The Game

WordPress plugin Sudoku - The Game scored 84% from 54 tests.

About plugin

  • Plugin page: sudoku-game
  • Plugin version: 1.0.9
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.7
  • WordPress version: 5.8.1
  • First release: Dec 2, 2016
  • Latest release: Jan 2, 2017
  • Number of updates: 23
  • Update frequency: every 0.9 days
  • Top authors: orcas2016 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active / 1,705 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲0.06MB] [CPU: ▼144.39ms] Passed 4 tests

An overview of server-side resources used by Sudoku - The Game
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.90 ▲0.0744.03 ▲8.32
Dashboard /wp-admin3.12 ▲0.0642.28 ▼2.46
Posts /wp-admin/edit.php3.20 ▲0.1047.39 ▲0.64
Add New Post /wp-admin/post-new.php5.47 ▲0.0491.94 ▼575.99
Media Library /wp-admin/upload.php3.06 ▲0.0634.02 ▲0.27

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 10 new files
Database: no new tables, 1 new option
New WordPress options
widget_sudoku_game

Browser metrics Passed 4 tests

A check of browser resources used by Sudoku - The Game
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,875 ▲27916.70 ▲0.7319.37 ▲7.0149.36 ▼3.22
Dashboard /wp-admin2,980 ▲466.28 ▲0.33182.32 ▲28.94108.58 ▼2.01
Posts /wp-admin/edit.php2,757 ▲182.91 ▲0.2078.11 ▲12.4289.83 ▼0.88
Add New Post /wp-admin/post-new.php1,696 ▲1318.88 ▲0.10434.72 ▲22.40116.47 ▲6.85
Media Library /wp-admin/upload.php1,762 ▼455.29 ▲0.28179.30 ▲25.35115.56 ▲0.99

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 1 option
    • widget_sudoku_game

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 50% 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 items
  • 3× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/sudoku-game/widget.php
    • > /wp-content/plugins/sudoku-game/sudoku-game.php
    • > /wp-content/plugins/sudoku-game/metatrait.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Screenshots: These screenshots do not have images: #1 (The sudoku widget in a website.), #2 (Backend configuration)
You can take inspiration from this readme.txt

sudoku-game/sudoku-game.php Passed 13 tests

The main PHP script in "Sudoku - The Game" version 1.0.9 is automatically included on every request by WordPress
56 characters long description:
Let visitors play the famous Sudoku-Game on your website

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
Good job! No executable or dangerous file extensions detected972 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript3140144769
PHP34510171
CSS19032

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity7.00
▷ Minimum class complexity1.00
▷ Maximum class complexity17.00
Average method complexity1.88
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces1
Interfaces0
Traits1
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods17
▷ Static methods529.41%
▷ Public methods17100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png20.34KB7.92KB▼ 61.05%
screenshot-1.png19.48KB7.33KB▼ 62.36%