84% wp-translate-shortcode

Code Review | WP Translate Shortcode

WordPress plugin WP Translate Shortcode scored84%from 54 tests.

About plugin

  • Plugin page: wp-translate-shor...
  • Plugin version: 0.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.9.4
  • WordPress version: 6.3.1
  • First release: Feb 16, 2018
  • Latest release: Feb 16, 2018
  • Number of updates: 2
  • Update frequency: every 1.0 days
  • Top authors: ejointjp (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /662 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼2.51ms] Passed 4 tests

Analyzing server-side resources used by WP Translate Shortcode
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0441.59 ▼3.78
Dashboard /wp-admin3.35 ▲0.0447.80 ▼3.57
Posts /wp-admin/edit.php3.40 ▲0.0448.77 ▲4.42
Add New Post /wp-admin/post-new.php5.93 ▲0.0490.39 ▼1.46
Media Library /wp-admin/upload.php3.27 ▲0.0435.16 ▼1.22
WP Translate /wp-admin/options-general.php?page=wptr-setting3.2334.00

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

WP Translate Shortcode: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,820 ▲7414.35 ▼0.382.01 ▲0.0343.05 ▼3.09
Dashboard /wp-admin2,196 ▲195.48 ▼0.2585.87 ▼0.9840.68 ▲4.58
Posts /wp-admin/edit.php2,104 ▲12.01 ▲0.0336.56 ▼4.0034.15 ▼0.87
Add New Post /wp-admin/post-new.php1,538 ▲318.51 ▲0.39614.63 ▼12.8260.80 ▼6.01
Media Library /wp-admin/upload.php1,398 ▲44.17 ▼0.0598.82 ▼7.2346.78 ▲4.35
WP Translate /wp-admin/options-general.php?page=wptr-setting8831.9924.4531.08

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function load_plugin_textdomain() in wp-content/plugins/wp-translate-shortcode/wp-translate-shortcode.php:39

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that need to be fixed:
  • Donate link: Please fix this invalid url: ""
You can look at the official readme.txt

wp-translate-shortcode/wp-translate-shortcode.php Passed 13 tests

The main file in "WP Translate Shortcode" v. 0.1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
74 characters long description:
It is a WordPress plugin that makes translate style easily with Shortcode.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected293 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP25634142
PO File13772105
Sass18345
CSS1001

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.17
Average class complexity11.00
▷ Minimum class complexity11.00
▷ Maximum class complexity11.00
Average method complexity2.11
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods9100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There were not PNG files found in your plugin