10% wopo-file-converter

Code Review | WoPo File Converter

WordPress plugin WoPo File Converter scored10%from 54 tests.

About plugin

  • Plugin page: wopo-file-converter
  • Plugin version: 1.1.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.2.2
  • WordPress version: 6.3.1
  • First release: Sep 3, 2021
  • Latest release: Nov 29, 2023
  • Number of updates: 6
  • Update frequency: every 136.2 days
  • Top authors: thanhbinh8703 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

50+ active /1,055 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The following installer errors require your attention
  • The plugin cannot be installed
    • > User error in wp-content/plugins/wopo-file-converter/vendor/composer/platform_check.php+24
    Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.1.0". You are running 7.4.16.

Server metrics [RAM: ▼1.90MB] [CPU: ▼56.36ms] Passed 4 tests

Server-side resources used by WoPo File Converter
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.10 ▼1.364.64 ▼38.03
Dashboard /wp-admin2.12 ▼1.236.35 ▼56.60
Posts /wp-admin/edit.php2.12 ▼1.246.94 ▼42.49
Add New Post /wp-admin/post-new.php2.12 ▼3.776.95 ▼88.33
Media Library /wp-admin/upload.php2.12 ▼1.117.20 ▼25.73

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 448 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for WoPo File Converter
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,817 ▲6614.78 ▲0.581.60 ▼0.1340.45 ▼11.61
Dashboard /wp-admin2,225 ▲455.64 ▲0.0495.96 ▼4.8773.08 ▲26.05
Posts /wp-admin/edit.php2,127 ▲301.96 ▼0.0439.79 ▲2.5635.51 ▲0.01
Add New Post /wp-admin/post-new.php1,550 ▲2422.70 ▼0.52688.06 ▲56.9155.71 ▲8.31
Media Library /wp-admin/upload.php1,427 ▲334.19 ▼0.0798.83 ▼0.2239.22 ▼3.86

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin cannot be uninstalled
    • > User error in wp-content/plugins/wopo-file-converter/vendor/composer/platform_check.php+24
    Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.1.0". You are running 7.4.16.
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% 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 everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 209× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Http\\Client\\Exception\\RequestException' not found in wp-content/plugins/wopo-file-converter/vendor/php-http/httplug/src/Exception/HttpException.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'Http\\Message\\Formatter' not found in wp-content/plugins/wopo-file-converter/vendor/php-http/message/src/Formatter/FullHttpMessageFormatter.php:15
    • > PHP Parse error
      syntax error, unexpected 'static' (T_STATIC) in wp-content/plugins/wopo-file-converter/vendor/symfony/options-resolver/OptionConfigurator.php on line 35
    • > PHP Fatal error
      Uncaught Error: Class 'GuzzleHttp\\Exception\\BadResponseException' not found in wp-content/plugins/wopo-file-converter/vendor/guzzlehttp/guzzle/src/Exception/ClientException.php:8
    • > PHP Warning
      require(wp-content/plugins/wopo-file-converter/vendor/cloudconvert/cloudconvert-php/tests/../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/wopo-file-converter/vendor/cloudconvert/cloudconvert-php/tests/bootstrap.php on line 2
    • > PHP Fatal error
      Uncaught LogicException: You cannot use "Http\\Message\\MessageFactory\\GuzzleStreamFactory" as the "php-http/message-factory" package is not installed. Try running "composer require php-http/message-factory". Note that this package is deprecated, use "psr/http-factory" instead in wp-content/plugins/wopo-file-converter/vendor/php-http/message/src/StreamFactory/GuzzleStreamFactory.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'CloudConvert\\Models\\Collection' not found in wp-content/plugins/wopo-file-converter/vendor/cloudconvert/cloudconvert-php/src/Models/JobCollection.php:7
    • > PHP Fatal error
      Uncaught Error: Interface 'Http\\Message\\Formatter' not found in wp-content/plugins/wopo-file-converter/vendor/php-http/message/src/Formatter/CurlCommandFormatter.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'GuzzleHttp\\Exception\\TransferException' not found in wp-content/plugins/wopo-file-converter/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'GuzzleHttp\\Exception\\GuzzleException' not found in wp-content/plugins/wopo-file-converter/vendor/guzzlehttp/guzzle/src/Exception/TransferException.php:5

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
6 plugin tags: converter, convert, wopo file converter, file converter, wopo...

wopo-file-converter/wopo-file-converter.php 77% from 13 tests

The principal PHP file in "WoPo File Converter" v. 1.1.0 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Domain Path: The domain path points to a folder that does not exist ("/languages")
  • Requires PHP: Required version must be the same as the one declared in readme.txt ("5.2.4" instead of "7.2")
  • Requires at least: Required version must be the same as the one declared in readme.txt ("4.7" instead of "5.2")

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,246 lines of code in 417 files:
LanguageFilesBlank linesComment linesLines of code
PHP3354,86910,75719,525
Markdown372,41205,465
JSON36003,098
YAML315075
XML40059
JavaScript11015
reStructuredText1409

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity8.22
▷ Minimum class complexity1.00
▷ Maximum class complexity139.00
Average method complexity2.56
▷ Minimum method complexity1.00
▷ Maximum method complexity48.00
Code structure
Namespaces53
Interfaces47
Traits14
Classes253
▷ Abstract classes93.56%
▷ Concrete classes24496.44%
▷ Final classes12752.05%
Methods1,472
▷ Static methods21114.33%
▷ Public methods1,24384.44%
▷ Protected methods573.87%
▷ Private methods17211.68%
Functions167
▷ Named functions3118.56%
▷ Anonymous functions13681.44%
Constants96
▷ Global constants44.17%
▷ Class constants9295.83%
▷ Public constants7783.70%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
vendor/cloudconvert/cloudconvert-php/tests/Integration/files/input.png45.84KB20.35KB▼ 55.61%