83% custom-currency-symbol-for-woocommerce

Code Review | Custom Currency Symbol for WooCommerce

WordPress plugin Custom Currency Symbol for WooCommerce scored83%from 54 tests.

About plugin

  • Plugin page: custom-currency-s...
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-5.2.2
  • WordPress version: 6.3.1
  • First release: Jun 27, 2019
  • Latest release: Jun 28, 2019
  • Number of updates: 6
  • Update frequency: every 1.2 days
  • Top authors: 3sonsdevelopment (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

3,000+ active /10,099 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

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

This is a short check of server-side resources used by Custom Currency Symbol for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0035.88 ▼5.39
Dashboard /wp-admin3.31 ▼0.0459.57 ▼1.53
Posts /wp-admin/edit.php3.36 ▲0.0042.19 ▼4.24
Add New Post /wp-admin/post-new.php5.89 ▲0.0080.06 ▼17.87
Media Library /wp-admin/upload.php3.23 ▲0.0036.90 ▲4.91

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

Custom Currency Symbol for WooCommerce: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.56 ▼0.871.65 ▼0.1142.01 ▼4.26
Dashboard /wp-admin2,206 ▲244.86 ▼1.05104.94 ▲4.7540.22 ▼2.04
Posts /wp-admin/edit.php2,089 ▲31.99 ▼0.0236.14 ▼1.4635.65 ▲1.40
Add New Post /wp-admin/post-new.php1,533 ▲1423.62 ▲0.54578.76 ▼84.6355.77 ▲0.27
Media Library /wp-admin/upload.php1,385 ▼64.22 ▼0.0698.46 ▼6.2240.86 ▼6.45

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options

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
Good news, no errors were detected

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
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/custom-currency-symbol-for-woocommerce/wc-custom-currency-symbol.php:29

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
2 plugin tags: currency, woocommerce

custom-currency-symbol-for-woocommerce/wc-custom-currency-symbol.php 77% from 13 tests

The entry point to "Custom Currency Symbol for WooCommerce" version 1.0.0 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Requires at least: The required version number must match the one declared in readme.txt ("5.1" instead of "3.6")
  • Main file name: The principal plugin file should be the same as the plugin slug ("custom-currency-symbol-for-woocommerce.php" instead of "wc-custom-currency-symbol.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin34 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1181234

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.58
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%
Functions3
▷ Named functions3100.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
No PNG files were detected