78% logo-manager-for-enamad

Code Review | Logo Manager For Enamad

WordPress plugin Logo Manager For Enamad scored78%from 54 tests.

About plugin

  • Plugin page: logo-manager-for-...
  • Plugin version: 0.7.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-6.0.2
  • WordPress version: 6.3.1
  • First release: Sep 21, 2015
  • Latest release: Sep 21, 2022
  • Number of updates: 11
  • Update frequency: every 232.5 days
  • Top authors: Goback2 (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

5,000+ active /44,503 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.03MB] [CPU: ▼8.02ms] Passed 4 tests

Server-side resources used by Logo Manager For Enamad
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0441.33 ▼1.40
Dashboard /wp-admin3.34 ▼0.0048.30 ▼16.13
Posts /wp-admin/edit.php3.45 ▲0.1049.62 ▼4.01
Add New Post /wp-admin/post-new.php5.92 ▲0.0492.73 ▼10.55
Media Library /wp-admin/upload.php3.26 ▲0.0439.29 ▲1.60
نماد الکترونیکی /wp-admin/options-general.php?page=enamadlogo-options3.2243.23

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 7 new files
Database: no new tables, 10 new options
New WordPress options
widget_theysaidso_widget
widget_enamad_widget
can_compress_scripts
widget_recent-posts
db_upgraded
enamad_logo
theysaidso_admin_options
widget_recent-comments
widget_enamad_shamed_widget
widget_enamad_custom_widget

Browser metrics Passed 4 tests

Checking browser requirements for Logo Manager For Enamad
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,794 ▲814.28 ▼0.061.83 ▼0.2942.15 ▼3.14
Dashboard /wp-admin2,199 ▲195.62 ▲0.0189.24 ▲0.0340.05 ▼4.01
Posts /wp-admin/edit.php2,104 ▲42.02 ▲0.0638.19 ▼2.6740.39 ▲2.58
Add New Post /wp-admin/post-new.php1,540 ▲1023.25 ▲0.30655.10 ▲12.5256.92 ▲12.24
Media Library /wp-admin/upload.php1,404 ▲44.20 ▲0.0199.56 ▼8.0247.38 ▲2.69
نماد الکترونیکی /wp-admin/options-general.php?page=enamadlogo-options1,0561.8929.3394.67

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options were found after uninstall: 10 options
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_enamad_shamed_widget
    • widget_enamad_custom_widget
    • widget_enamad_widget
    • widget_theysaidso_widget
    • widget_recent-posts
    • enamad_logo
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 3× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/logo-manager-for-enamad/index.php
    • > /wp-content/plugins/logo-manager-for-enamad/simple-class-options.php
    • > /wp-content/plugins/logo-manager-for-enamad/fns.php
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/logo-manager-for-enamad/widgets.php:7

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser 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
9 plugin tags: shamed, iran, enamad logo, wordpress enamad, wordpress enamad plugin...

logo-manager-for-enamad/index.php 85% from 13 tests

The primary PHP file in "Logo Manager For Enamad" version 0.7.0 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("logo-manager-for-enamad.php" instead of "index.php")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 213 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin619 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP4127130601
HTML101118

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity6.20
▷ Minimum class complexity5.00
▷ Maximum class complexity11.00
Average method complexity2.30
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods20
▷ Static methods00.00%
▷ Public methods20100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
logo.png3.76KB1.55KB▼ 58.75%