10% cutup-machine

Code Review | CutUp Machine

WordPress plugin CutUp Machine scored10%from 54 tests.

About plugin

  • Plugin page: cutup-machine
  • Plugin version: 1...
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jul 19, 2014
  • Latest release: Sep 4, 2014
  • Number of updates: 6
  • Update frequency: every 8.8 days
  • Top authors: languageisavirus (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /787 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
These installer errors require your attention
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/cutup-machine/cutupmachine.php+31
    Methods with the same name as their class will not be constructors in a future version of PHP; CutUpMachine has a deprecated constructor

Server metrics [RAM: ▼1.92MB] [CPU: ▼53.14ms] Passed 4 tests

A check of server-side resources used by CutUp Machine
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.06 ▼1.404.70 ▼35.56
Dashboard /wp-admin2.08 ▼1.225.36 ▼45.05
Posts /wp-admin/edit.php2.08 ▼1.275.34 ▼42.02
Add New Post /wp-admin/post-new.php2.08 ▼3.805.66 ▼89.94
Media Library /wp-admin/upload.php2.08 ▼1.155.67 ▼26.66

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-posts
widget_cutupmachine
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

CutUp Machine: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.34 ▼0.961.75 ▼0.0343.30 ▼5.37
Dashboard /wp-admin2,209 ▲186.06 ▲1.17104.58 ▲2.2240.05 ▼4.43
Posts /wp-admin/edit.php2,086 ▼31.97 ▼0.0335.34 ▼2.8637.09 ▲1.89
Add New Post /wp-admin/post-new.php1,542 ▲918.15 ▼5.10602.14 ▼64.2668.84 ▲16.81
Media Library /wp-admin/upload.php1,391 ▼04.24 ▲0.0397.29 ▼3.1641.45 ▼0.80

Uninstaller [IO: ▲0.00MB] [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
    • > Deprecated in wp-content/plugins/cutup-machine/cutupmachine.php+31
    Methods with the same name as their class will not be constructors in a future version of PHP; CutUpMachine has a deprecated constructor
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_cutupmachine
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

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

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/cutup-machine/cutupmachine.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 83% from 29 tests

readme.txt 81% from 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
These attributes need your attention:
  • Screenshots: Add an image for screenshot #1 (CutUp Machine widget in sidebar)
  • Requires at least: The plugin version is formatted incorrectly
  • Tested up to: The plugin version is formatted incorrectly
Please take inspiration from this readme.txt

cutup-machine/cutupmachine.php 85% from 13 tests

The principal PHP file in "CutUp Machine" v. 1... is loaded by WordPress automatically on each request
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("cutup-machine.php" instead of "cutupmachine.php")
  • Version: Plugin version number should only contain digits separated by dots (ex. "1.0.3" instead of "1...")

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 plugin105 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript12061
PHP1202144

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.12
Average class complexity3.00
▷ Minimum class complexity3.00
▷ Maximum class complexity3.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 PNG file occupies 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png47.78KB17.37KB▼ 63.63%