84% emojin

Code Review | Emojin

WordPress plugin Emojin scored84%from 54 tests.

About plugin

  • Plugin page: emojin
  • Plugin version: 0.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 2.7.0-4.0.0
  • WordPress version: 6.3.1
  • First release: Aug 24, 2014
  • Latest release: Sep 8, 2014
  • Number of updates: 3
  • Update frequency: every 5.0 days
  • Top authors: tmatsuur (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,507 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.13ms] Passed 4 tests

Analyzing server-side resources used by Emojin
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.39 ▼2.49
Dashboard /wp-admin3.32 ▼0.0350.15 ▼12.79
Posts /wp-admin/edit.php3.37 ▲0.0148.18 ▼1.95
Add New Post /wp-admin/post-new.php5.90 ▲0.0191.50 ▼7.27
Media Library /wp-admin/upload.php3.24 ▲0.0138.52 ▼0.11

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Emojin
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.25 ▼0.331.72 ▼0.3740.11 ▼6.60
Dashboard /wp-admin2,192 ▲145.57 ▼0.0593.54 ▼11.2144.99 ▲1.16
Posts /wp-admin/edit.php2,100 ▼01.97 ▲0.0235.14 ▼1.3434.62 ▼3.93
Add New Post /wp-admin/post-new.php1,526 ▼023.29 ▲0.43671.47 ▲18.9052.34 ▼2.17
Media Library /wp-admin/upload.php1,400 ▼34.23 ▼0.0697.57 ▼8.7141.86 ▼7.17

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
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check 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 | 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
Almost there! Just fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/emojin/emojin.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Screenshots: Screenshot #1 (Plug-in is activated, and post is saved.) image not found
You can look at the official readme.txt

emojin/emojin.php Passed 13 tests

The entry point to "Emojin" version 0.1.0 is a PHP file that has certain tags in its header comment area
77 characters long description:
If emoji is included in the post content, this plug-in escaped before saving.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin32 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP131232

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods266.67%
▷ Protected methods00.00%
▷ Private methods133.33%
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
1 PNG file occupies 0.04MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png45.32KB16.69KB▼ 63.17%