72% microthemer

Code Review | Microthemer Lite - Visual Editor to Customize CSS

WordPress plugin Microthemer Lite - Visual Editor to Customize CSS scored72%from 54 tests.

About plugin

  • Plugin page: microthemer
  • Plugin version: 7.2.4.9
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.4
  • WordPress version: 6.3.1
  • First release: Jul 6, 2013
  • Latest release: Nov 22, 2023
  • Number of updates: 421
  • Update frequency: every 9.0 days
  • Top authors: bastywebb (100%)

Code review

54 tests

User reviews

41 reviews

Install metrics

20,000+ active /2,164,465 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲1.69MB] [CPU: ▲4.89ms] Passed 4 tests

Server-side resources used by Microthemer Lite - Visual Editor to Customize CSS
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.71 ▲0.2538.06 ▼4.52
Dashboard /wp-admin5.48 ▲2.1862.52 ▲10.58
Posts /wp-admin/edit.php5.51 ▲2.1568.15 ▲21.33
Add New Post /wp-admin/post-new.php8.08 ▲2.2096.97 ▼1.80
Media Library /wp-admin/upload.php5.41 ▲2.1850.27 ▲15.30

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 156 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Microthemer Lite - Visual Editor to Customize CSS
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,919 ▲15713.84 ▼0.508.87 ▲7.1537.43 ▼6.24
Dashboard /wp-admin2,225 ▲455.59 ▼0.0296.29 ▼2.8642.12 ▼1.41
Posts /wp-admin/edit.php2,133 ▲332.02 ▲0.0140.09 ▲0.2835.77 ▼5.75
Add New Post /wp-admin/post-new.php1,554 ▲2823.43 ▼0.18648.62 ▼17.5968.51 ▼2.00
Media Library /wp-admin/upload.php1,427 ▲304.20 ▲0.00100.28 ▲1.1242.60 ▲2.56
Manage Packs /wp-admin/tvr-manage-micro-themes.php260.410.1413.70
Fonts /wp-admin/tvr-fonts.php260.410.096.54
Microthemer /wp-admin/tvr-microthemer.php260.410.067.42
Documentation /wp-admin/tvr-docs.php260.410.085.12
Preferences /wp-admin/tvr-microthemer-preferences.php260.410.096.04
Detached Preview /wp-admin/tvr-microthemer-preview-wrap.php260.410.107.07
Manage Single Pack /wp-admin/tvr-manage-single.php260.410.125.40

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
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

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
Please fix the following items
  • 13× PHP files perform the task of outputting text when accessed with GET requests (only 10 are shown):
    • > /wp-content/plugins/microthemer/includes/tvr-microthemer-preferences.php
    • > /wp-content/plugins/microthemer/includes/tvr-manage-single.php
    • > /wp-content/plugins/microthemer/includes/tvr-microthemer-preview-wrap.php
    • > /wp-content/plugins/microthemer/includes/program-data.php
    • > /wp-content/plugins/microthemer/includes/resolve-input-fields.inc.php
    • > /wp-content/plugins/microthemer/includes/tvr-microthemer-ui.php
    • > /wp-content/plugins/microthemer/includes/common-inline-assets.php
    • > /wp-content/plugins/microthemer/get-dir-paths.inc.php
    • > /wp-content/plugins/microthemer/includes/internal-docs.php
    • > /wp-content/plugins/microthemer/includes/grid-control.inc.php
  • 12× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Microthemer\\Dependencies\\Minify\\Exceptions\\BasicException' not found in wp-content/plugins/microthemer/src/Dependencies/Minify/minify/src/Exceptions/IOException.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'Microthemer\\AssetLoad' not found in wp-content/plugins/microthemer/src/AssetAuth.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'Microthemer\\Dependencies\\Minify\\Minify' not found in wp-content/plugins/microthemer/src/Dependencies/Minify/minify/src/JS.php:25
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html__() in wp-content/plugins/microthemer/includes/js-i18n.inc.php:6
    • > PHP Fatal error
      Uncaught Error: Interface 'Microthemer\\Dependencies\\Minify\\PathConverter\\ConverterInterface' not found in wp-content/plugins/microthemer/src/Dependencies/Minify/path-converter/src/Converter.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'Microthemer\\Dependencies\\Minify\\Minify' not found in wp-content/plugins/microthemer/src/Dependencies/Minify/minify/src/CSS.php:29
    • > PHP Fatal error
      Uncaught Error: Interface 'Microthemer\\Dependencies\\Minify\\PathConverter\\ConverterInterface' not found in wp-content/plugins/microthemer/src/Dependencies/Minify/path-converter/src/NoConverter.php:14
    • > PHP Fatal error
      Trait 'Microthemer\\PluginTrait' not found in wp-content/plugins/microthemer/src/Admin.php on line 5
    • > PHP Fatal error
      Uncaught Error: Class 'Microthemer\\Dependencies\\Minify\\Exception' not found in wp-content/plugins/microthemer/src/Dependencies/Minify/minify/src/Exceptions/BasicException.php:22
    • > PHP Warning
      Use of undefined constant TVR_DEV_MODE - assumed 'TVR_DEV_MODE' (this will throw an Error in a future version of PHP) in wp-content/plugins/microthemer/includes/js-dynamic.php on line 10

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please fix the following browser errors
    • > GET request to /wp-admin/tvr-manage-micro-themes.php
    • > Network (severe)
    wp-admin/tvr-manage-micro-themes.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/tvr-fonts.php
    • > Network (severe)
    wp-admin/tvr-fonts.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/tvr-microthemer.php
    • > Network (severe)
    wp-admin/tvr-microthemer.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/tvr-docs.php
    • > Network (severe)
    wp-admin/tvr-docs.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/tvr-microthemer-preferences.php
    • > Network (severe)
    wp-admin/tvr-microthemer-preferences.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/tvr-microthemer-preview-wrap.php
    • > Network (severe)
    wp-admin/tvr-microthemer-preview-wrap.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/tvr-manage-single.php
    • > Network (severe)
    wp-admin/tvr-manage-single.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
5 plugin tags: css, visual editor, responsive, customize, google fonts

microthemer/tvr-microthemer.php 85% from 13 tests

The main PHP script in "Microthemer Lite - Visual Editor to Customize CSS" version 7.2.4.9 is automatically included on every request by WordPress
The following require your attention:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 454 characters long)
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("microthemer.php" instead of "tvr-microthemer.php")

Code Analysis 95% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected42,522 lines of code in 120 files:
LanguageFilesBlank linesComment linesLines of code
PHP455,9255,70428,776
PO File32,5282,9167,328
CSS13559824,776
JavaScript472803721,325
JSON300229
SVG80080
XML1208

PHP code 0% from 2 tests

This plugin's cyclomatic complexity and code structure detailed below
The following items need your attention
  • Please reduce cyclomatic complexity of classes to less than 1000 (currently 1,236)
  • Cyclomatic complexity of methods should be reduced to less than 100 (currently 131)
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity89.12
▷ Minimum class complexity1.00
▷ Maximum class complexity1,236.00
Average method complexity5.69
▷ Minimum method complexity1.00
▷ Maximum method complexity131.00
Code structure
Namespaces4
Interfaces1
Traits8
Classes16
▷ Abstract classes318.75%
▷ Concrete classes1381.25%
▷ Final classes00.00%
Methods481
▷ Static methods132.70%
▷ Public methods43490.23%
▷ Protected methods479.77%
▷ Private methods00.00%
Functions30
▷ Named functions1446.67%
▷ Anonymous functions1653.33%
Constants18
▷ Global constants1794.44%
▷ Class constants15.56%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/trans-big.png1.00KB0.16KB▼ 84.26%
images/trans-big-dark.png0.92KB0.09KB▼ 90.29%