79% automatic-translate-slug

Code Review | Automatic Translate Slug

WordPress plugin Automatic Translate Slug scored79%from 54 tests.

About plugin

  • Plugin page: automatic-transla...
  • Plugin version: 1.0.2
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.1
  • WordPress version: 6.3.1
  • First release: Feb 24, 2019
  • Latest release: Feb 24, 2019
  • Number of updates: 8
  • Update frequency: every 0.1 days
  • Top authors: bestony (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /795 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.68MB] [CPU: ▼14.49ms] Passed 4 tests

Server-side resources used by Automatic Translate Slug
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0239.54 ▼1.95
Dashboard /wp-admin3.34 ▲0.0353.36 ▲2.72
Posts /wp-admin/edit.php3.39 ▲0.0348.20 ▲0.68
Add New Post /wp-admin/post-new.php3.10 ▼2.7929.30 ▼59.42
Media Library /wp-admin/upload.php3.26 ▲0.0337.48 ▲3.41
Automatic Translate Slug /wp-admin/options-general.php?page=automatic_translate_slug3.2029.77

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 9 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Automatic Translate Slug
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.09 ▼0.261.77 ▼0.1143.55 ▼4.47
Dashboard /wp-admin2,199 ▲225.65 ▲0.0886.79 ▼13.6938.11 ▼5.44
Posts /wp-admin/edit.php2,104 ▲11.95 ▼0.0634.75 ▼2.4335.79 ▲0.89
Add New Post /wp-admin/post-new.php1,531 ▼623.10 ▲5.05659.39 ▲1.4952.58 ▼8.89
Media Library /wp-admin/upload.php1,401 ▲14.22 ▼0.0294.77 ▲0.3443.65 ▼1.10
Automatic Translate Slug /wp-admin/options-general.php?page=automatic_translate_slug8721.9621.4527.15

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
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
  • 7 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=automatic_translate_slug
    • > Notice in wp-content/plugins/automatic-translate-slug/options.php+85
    Trying to access array offset on value of type bool

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
Please fix the following items
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/automatic-translate-slug/options.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/automatic-translate-slug/automatic-translate-slug.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
1 plugin tags: slug

automatic-translate-slug/automatic-translate-slug.php Passed 13 tests

"Automatic Translate Slug" version 1.0.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
32 characters long description:
Make Your Post Slug Into English

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
No dangerous file extensions were detected244 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP44212184
PO File1202360

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.09
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.25
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods8
▷ Static methods00.00%
▷ Public methods450.00%
▷ Protected methods00.00%
▷ Private methods450.00%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin