10% wp-emoji-sanitizer

Code Review | WordPress Emoji Remover & Sanitizer

WordPress plugin WordPress Emoji Remover & Sanitizer scored10%from 54 tests.

About plugin

  • Plugin page: wp-emoji-sanitizer
  • Plugin version: 2.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Dec 30, 2018
  • Latest release: Nov 30, 2023
  • Number of updates: 27
  • Update frequency: every 66.5 days
  • Top authors: isrgrajan (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

100+ active /2,901 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The following installer errors require your attention
  • This plugin did not install gracefully
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)

Server metrics [RAM: ▼1.93MB] [CPU: ▼55.83ms] Passed 4 tests

Server-side resources used by WordPress Emoji Remover & Sanitizer
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.07 ▼1.394.17 ▼35.38
Dashboard /wp-admin2.09 ▼1.2510.75 ▼52.20
Posts /wp-admin/edit.php2.09 ▼1.265.89 ▼38.93
Add New Post /wp-admin/post-new.php2.09 ▼3.795.55 ▼96.81
Media Library /wp-admin/upload.php2.09 ▼1.144.95 ▼29.07
Emoji Sanitizer /wp-admin/options-general.php?page=wpemojisanitizer_settings2.095.78

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
wpemojisanitizer_options
widget_recent-posts
db_upgraded
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by WordPress Emoji Remover & Sanitizer
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,788 ▲4114.22 ▼0.141.40 ▼0.2736.97 ▼6.90
Dashboard /wp-admin2,196 ▲195.61 ▼0.0494.31 ▼0.0239.50 ▲1.35
Posts /wp-admin/edit.php2,107 ▲72.03 ▲0.0238.61 ▼4.5736.70 ▼0.12
Add New Post /wp-admin/post-new.php1,537 ▲1023.23 ▼0.01581.45 ▼11.6955.29 ▲2.53
Media Library /wp-admin/upload.php1,404 ▲44.22 ▲0.0196.06 ▼3.2941.57 ▲0.41
Emoji Sanitizer /wp-admin/options-general.php?page=wpemojisanitizer_settings8761.9927.5725.64

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • This plugin did not uninstall without warnings or errors
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)
  • This plugin does not fully uninstall, leaving 7 options in the database
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • wpemojisanitizer_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=wpemojisanitizer_settings
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
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_action() in wp-content/plugins/wp-emoji-sanitizer/wp-emoji-sanitizer.php:19

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 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: emoji, sanitizer, wordpress

wp-emoji-sanitizer/wp-emoji-sanitizer.php 85% from 13 tests

"WordPress Emoji Remover & Sanitizer" version 2.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • 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
  • Description: Please keep the plugin description shorter than 140 characters (currently 155 characters long)

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
Success! There were no dangerous files found in this plugin113 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP11613113

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.11
Average class complexity5.00
▷ Minimum class complexity5.00
▷ Maximum class complexity5.00
Average method complexity1.44
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods9100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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 images were found in this plugin