79% emoji-reaction-rating

Code Review | Emoji Reaction Rating

WordPress plugin Emoji Reaction Rating scored79%from 54 tests.

About plugin

  • Plugin page: emoji-reaction-ra...
  • Plugin version: 1.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.3
  • WordPress version: 6.3.1
  • First release: Dec 31, 2019
  • Latest release: Apr 3, 2020
  • Number of updates: 7
  • Update frequency: every 13.4 days
  • Top authors: dynathemes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /1,680 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.21MB] [CPU: ▼6.69ms] Passed 4 tests

Analyzing server-side resources used by Emoji Reaction Rating
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.63 ▲0.1623.04 ▼21.30
Dashboard /wp-admin3.58 ▲0.2751.52 ▼2.46
Posts /wp-admin/edit.php3.63 ▲0.2851.91 ▲6.95
Add New Post /wp-admin/post-new.php6.10 ▲0.2182.90 ▼2.82
Media Library /wp-admin/upload.php3.42 ▲0.1935.19 ▼0.19
Emoji Reaction Rating Settings /wp-admin/options-general.php?page=emoji-reaction-rating-settings-page3.3832.18

Server storage [IO: ▲0.35MB] [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: 38 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
db_upgraded
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

Emoji Reaction Rating: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,075 ▲32915.11 ▲0.957.08 ▲5.3337.05 ▼6.61
Dashboard /wp-admin2,351 ▲1696.44 ▲1.55121.59 ▲5.9637.88 ▼11.45
Posts /wp-admin/edit.php2,254 ▲1653.34 ▲1.3350.26 ▲13.8732.34 ▼4.19
Add New Post /wp-admin/post-new.php1,520 ▲123.17 ▼0.06628.89 ▼47.4336.03 ▼18.49
Media Library /wp-admin/upload.php1,396 ▲114.10 ▼0.0979.03 ▼21.3441.02 ▼1.08
Emoji Reaction Rating Settings /wp-admin/options-general.php?page=emoji-reaction-rating-settings-page1,1273.0239.1263.44

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Please fix the following server-side errors
  • 11 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=emoji-reaction-rating-settings-page
    • > Notice in wp-content/plugins/emoji-reaction-rating/includes/callbacks/Actions.php+167
    Trying to access array offset on value of type bool
  • 20 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=emoji-reaction-rating-settings-page
    • > Notice in wp-content/plugins/emoji-reaction-rating/includes/callbacks/Actions.php+167
    Trying to access array offset on value of type null

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× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/emoji-reaction-rating/emoji-reaction-rating.php:32

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
6 plugin tags: post reaction, article rating, post feedback, emoji reaction rating, post rating...

emoji-reaction-rating/emoji-reaction-rating.php Passed 13 tests

The entry point to "Emoji Reaction Rating" version 1.1 is a PHP file that has certain tags in its header comment area
70 characters long description:
A useful plugin to create Emoji based Reaction Ratings for post types.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected1,076 lines of code in 25 files:
LanguageFilesBlank linesComment linesLines of code
PHP19191398840
CSS2220126
JavaScript281101
JSON2009

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.37
Average class complexity9.38
▷ Minimum class complexity1.00
▷ Maximum class complexity44.00
Average method complexity2.68
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes13
▷ Abstract classes00.00%
▷ Concrete classes13100.00%
▷ Final classes00.00%
Methods66
▷ Static methods1218.18%
▷ Public methods6496.97%
▷ Protected methods00.00%
▷ Private methods23.03%
Functions3
▷ Named functions266.67%
▷ Anonymous functions133.33%
Constants8
▷ Global constants8100.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
8 PNG files occupy 0.26MB with 0.17MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-2.png91.43KB26.55KB▼ 70.97%
resources/images/3.png5.42KB2.10KB▼ 61.18%
resources/images/4.png5.63KB2.16KB▼ 61.63%
assets/screenshot-3.png59.11KB17.60KB▼ 70.22%
resources/images/2.png5.46KB2.13KB▼ 60.93%