84% language-mix

Code Review | Language Mix

WordPress plugin Language Mix scored84%from 54 tests.

About plugin

  • Plugin page: language-mix
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.1-3.7.1
  • WordPress version: 6.3.1
  • First release: Jan 12, 2014
  • Latest release: Feb 16, 2014
  • Number of updates: 8
  • Update frequency: every 4.4 days
  • Top authors: s-andy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,728 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
This plugin's installer ran successfully

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

This is a short check of server-side resources used by Language Mix
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0036.81 ▲1.85
Dashboard /wp-admin3.31 ▼0.0445.82 ▼9.26
Posts /wp-admin/edit.php3.36 ▲0.0043.56 ▼6.79
Add New Post /wp-admin/post-new.php5.89 ▲0.0080.80 ▼18.92
Media Library /wp-admin/upload.php3.23 ▲0.0032.78 ▼2.08

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

How much does this plugin use your filesystem and database?
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
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Language Mix
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.27 ▼0.081.67 ▼0.2038.83 ▼2.21
Dashboard /wp-admin2,198 ▲185.52 ▼0.0890.28 ▲5.0239.58 ▲1.07
Posts /wp-admin/edit.php2,100 ▼31.98 ▼0.0335.14 ▼2.8931.68 ▲0.64
Add New Post /wp-admin/post-new.php1,526 ▼222.76 ▼0.26616.56 ▲9.9856.57 ▼2.21
Media Library /wp-admin/upload.php1,394 ▼64.30 ▲0.0599.46 ▼6.7748.94 ▲2.28

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 5× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/plugin.php' (include_path='.:/usr/share/php') in wp-content/plugins/language-mix/language-mix.php on line 35
    • > PHP Warning
      require_once(ABSPATHwp-admin/includes/plugin.php): failed to open stream: No such file or directory in wp-content/plugins/language-mix/language-mix.php on line 35
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/language-mix/widgets/languages.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/language-mix/widgets/translations.php:5
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/language-mix/language-mix.php on line 35

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
6 plugin tags: multilingual, widget, translations, browser languages, cookies...

language-mix/language-mix.php Passed 13 tests

The principal PHP file in "Language Mix" v. 1.0 is loaded by WordPress automatically on each request
62 characters long description:
This plugin unhides contents which are in languages you speak.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin449 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP374110387
PO File2162062

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity7.00
▷ Minimum class complexity5.00
▷ Maximum class complexity9.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods8
▷ Static methods00.00%
▷ Public methods8100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions19
▷ Named functions19100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
No PNG images were found in this plugin