84% admin-in-english-with-switch

Code Review | Admin in English with Switch

WordPress plugin Admin in English with Switch scored84%from 54 tests.

About plugin

  • Plugin page: admin-in-english-...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-3.5
  • WordPress version: 6.3.1
  • First release: Jan 29, 2013
  • Latest release: Jan 31, 2013
  • Number of updates: 15
  • Update frequency: every 0.1 days
  • Top authors: dontcare (100%)

Code review

54 tests

User reviews

8 reviews

Install metrics

70+ active /4,644 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼4.09ms] Passed 4 tests

Analyzing server-side resources used by Admin in English with Switch
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0144.71 ▲2.04
Dashboard /wp-admin3.37 ▼0.0248.17 ▼13.84
Posts /wp-admin/edit.php3.48 ▲0.0852.84 ▲2.14
Add New Post /wp-admin/post-new.php5.95 ▲0.0291.07 ▼6.69
Media Library /wp-admin/upload.php3.29 ▲0.0240.42 ▲4.37

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Admin in English with Switch
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,041 ▲28015.54 ▲0.9610.13 ▲8.2943.57 ▼0.74
Dashboard /wp-admin2,276 ▲966.09 ▲0.5195.76 ▲2.7437.09 ▼5.98
Posts /wp-admin/edit.php2,190 ▲873.09 ▲1.0752.63 ▲15.2657.52 ▲19.70
Add New Post /wp-admin/post-new.php1,493 ▼3320.44 ▼2.53481.57 ▼183.6622.52 ▼32.14
Media Library /wp-admin/upload.php1,490 ▲905.72 ▲1.58111.75 ▲5.0039.57 ▼6.84

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means 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
Please fix the following items
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/admin-in-english-with-switch/admin-in-english-with-switch.php on line 12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_get_current_user() in wp-content/plugins/admin-in-english-with-switch/admin-in-english-with-switch.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
6 plugin tags: i18n, localization, translations, backend, translation...

admin-in-english-with-switch/admin-in-english-with-switch.php 92% from 13 tests

The principal PHP file in "Admin in English with Switch" v. 1.1 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 317 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected102 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP1181491
JavaScript10011

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.54
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.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

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected