99% find-and-replace-one-language-wpml

Code Review | Find and Replace for one language in WPML

WordPress plugin Find and Replace for one language in WPML scored 99% from 54 tests.

About plugin

  • Plugin page: find-and-replace-...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.4
  • WordPress version: 5.8.1
  • First release: Jul 9, 2020
  • Latest release: Jul 10, 2020
  • Number of updates: 5
  • Update frequency: every 1.8 days
  • Top authors: stouch (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 212 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

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

Server-side resources used by Find and Replace for one language in WPML
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.1333.42 ▲9.95
Dashboard /wp-admin3.07 ▲0.0246.94 ▲0.03
Posts /wp-admin/edit.php3.13 ▲0.0247.20 ▲0.36
Add New Post /wp-admin/post-new.php5.43 ▼0.0084.79 ▼559.77
Media Library /wp-admin/upload.php3.02 ▲0.0234.46 ▼2.52

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 3 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Find and Replace for one language in WPML
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,718 ▲12216.19 ▲0.5011.90 ▲0.7549.16 ▲1.01
Dashboard /wp-admin2,982 ▲485.85 ▼0.10142.95 ▼5.52111.13 ▼0.78
Posts /wp-admin/edit.php2,754 ▲152.85 ▲0.1464.49 ▲0.5689.16 ▲1.92
Add New Post /wp-admin/post-new.php1,886 ▲28219.21 ▲0.31459.63 ▲78.30105.85 ▼14.27
Media Library /wp-admin/upload.php1,825 ▲215.01 ▲0.01150.90 ▼0.07109.93 ▼0.95

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
This plugin's uninstaller ran successfully

Smoke tests Passed 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 Passed 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Everything seems fine, however this is by no means an exhaustive test

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

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
8 plugin tags: php, wpml, replace, mysql, wp...

find-and-replace-one-language-wpml/Find-and-Replace-for-one-language-in-WPML.php 77% from 13 tests

The main file in "Find and Replace for one language in WPML" v. 1.0.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("find-and-replace-one-language-wpml.php" instead of "Find-and-Replace-for-one-language-in-WPML.php")
  • Domain Path: The domain path folder was not found ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin64 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2292564

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.29
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%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There are no PNG files in this plugin