84% emnon-localized-link-creator

Code Review | Emnon Localized Link Creator

WordPress plugin Emnon Localized Link Creator scored84%from 54 tests.

About plugin

  • Plugin page: emnon-localized-l...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2.2-4.6.1
  • WordPress version: 6.3.1
  • First release: Oct 31, 2016
  • Latest release: Oct 31, 2016
  • Number of updates: 5
  • Update frequency: N/A
  • Top authors: sajjadul (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /575 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

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

Server-side resources used by Emnon Localized Link Creator
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.61 ▲0.44
Dashboard /wp-admin3.31 ▲0.0146.27 ▼1.78
Posts /wp-admin/edit.php3.36 ▲0.0151.22 ▲1.34
Add New Post /wp-admin/post-new.php5.89 ▲0.0182.93 ▼10.21
Media Library /wp-admin/upload.php3.23 ▲0.0135.32 ▲0.59
Emnon affiliate /wp-admin/options-general.php?page=emaf_affiliate3.2631.82

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 31 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Emnon Localized Link Creator
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,807 ▲6114.41 ▼0.181.55 ▼0.1442.29 ▲1.62
Dashboard /wp-admin2,213 ▲255.80 ▼0.10104.04 ▲4.9937.64 ▼10.33
Posts /wp-admin/edit.php2,093 ▲42.05 ▲0.0738.29 ▲4.0131.10 ▼6.24
Add New Post /wp-admin/post-new.php1,530 ▼323.12 ▲0.13677.17 ▲13.0886.25 ▲31.28
Media Library /wp-admin/upload.php1,392 ▲14.21 ▲0.02103.13 ▲5.9245.69 ▲0.26
Emnon affiliate /wp-admin/options-general.php?page=emaf_affiliate8712.1732.31108.46

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=emaf_affiliate
    • > Notice in wp-content/plugins/emnon-localized-link-creator/settings-sub-menu.php+34
    Undefined index: tab

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Please fix the following attributes:
  • Tags: Too many tags (15 tag instead of maximum 10); only the first 5 tags are used in your directory listing
Please take inspiration from this readme.txt

emnon-localized-link-creator/emnon-affiliate.php 92% from 13 tests

The primary PHP file in "Emnon Localized Link Creator" version 1.0 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("emnon-localized-link-creator.php" instead of "emnon-affiliate.php")

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 plugin11,269 lines of code in 20 files:
LanguageFilesBlank linesComment linesLines of code
CSS659778,603
JavaScript56002061,727
PHP86818651
SVG100288

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.37
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%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 PNG file occupies 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
js/img/emaflink.png5.58KB2.96KB▼ 47.09%