78% persian-admin-fonts

Code Review | Persian Admnin Fonts

WordPress plugin Persian Admnin Fonts scored78%from 54 tests.

About plugin

  • Plugin page: persian-admin-fonts
  • Plugin version: 4.0.25
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Nov 13, 2021
  • Latest release: Nov 17, 2023
  • Number of updates: 38
  • Update frequency: every 19.3 days
  • Top authors: mdesignfa (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /5,802 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.10MB] [CPU: ▼0.09ms] Passed 4 tests

Analyzing server-side resources used by Persian Admnin Fonts
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0346.14 ▲5.68
Dashboard /wp-admin3.42 ▲0.1248.38 ▼1.34
Posts /wp-admin/edit.php3.54 ▲0.1852.22 ▲12.22
Add New Post /wp-admin/post-new.php6.00 ▲0.1282.78 ▼4.94
Media Library /wp-admin/upload.php3.35 ▲0.1234.49 ▲0.25
Persian-Fonts /wp-admin/options-general.php?page=persian-fonts-options3.9153.87

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 253 new files
Database: no new tables, 8 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
pfmdz_redirect_onActivate
widget_recent-comments
pfmdz_empty_onDeactivate
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Persian Admnin Fonts
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,794 ▲4714.27 ▼0.111.60 ▼0.1342.58 ▼2.42
Dashboard /wp-admin2,196 ▲165.54 ▼0.1187.97 ▼9.7338.22 ▼4.41
Posts /wp-admin/edit.php2,107 ▲41.97 ▲0.0340.82 ▼0.8436.78 ▼1.99
Add New Post /wp-admin/post-new.php1,529 ▲323.45 ▲0.25704.29 ▲39.5866.44 ▲14.51
Media Library /wp-admin/upload.php1,407 ▲44.15 ▼0.0698.50 ▲0.3843.35 ▲0.12
Persian-Fonts /wp-admin/options-general.php?page=persian-fonts-options3,6721.6627.1199.60

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
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 8 options
    • pfmdz_redirect_onActivate
    • theysaidso_admin_options
    • pfmdz_empty_onDeactivate
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Smoke test failed, please fix the following
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=persian-fonts-options
    • > Notice in wp-content/plugins/persian-admin-fonts/templates/html/settingspagehtml.php+1352
    Undefined offset: 1

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
Please fix the following
  • 12× GET requests to PHP files return non-empty strings (only 10 are shown):
    • > /wp-content/plugins/persian-admin-fonts/admin/class-admin.php
    • > /wp-content/plugins/persian-admin-fonts/templates/html/settingspagehtml.php
    • > /wp-content/plugins/persian-admin-fonts/templates/html/our-fav-fonts.php
    • > /wp-content/plugins/persian-admin-fonts/templates/html/help3html.php
    • > /wp-content/plugins/persian-admin-fonts/templates/html/help4html.php
    • > /wp-content/plugins/persian-admin-fonts/templates/html/help1html.php
    • > /wp-content/plugins/persian-admin-fonts/templates/html/help2html.php
    • > /wp-content/plugins/persian-admin-fonts/templates/html/our-services.php
    • > /wp-content/plugins/persian-admin-fonts/persianadminfonts-bymdez.php
    • > /wp-content/plugins/persian-admin-fonts/front/class-front.php

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)
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
1 plugin tags: free farsi fonts for wp-admin

persian-admin-fonts/persianadminfonts-bymdez.php 85% from 13 tests

The principal PHP file in "Persian Admnin Fonts" v. 4.0.25 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("persian-admin-fonts.php" instead of "persianadminfonts-bymdez.php")
  • 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

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
There were no executable files found in this plugin3,319 lines of code in 25 files:
LanguageFilesBlank linesComment linesLines of code
PHP136461312,366
PO File1183240612
SVG505244
CSS517296
JavaScript1001

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity20.50
▷ Minimum class complexity4.00
▷ Maximum class complexity37.00
Average method complexity2.45
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods23
▷ Static methods14.35%
▷ Public methods23100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions10
▷ Named functions660.00%
▷ Anonymous functions440.00%
Constants4
▷ Global constants4100.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
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
admin/img/close.png1.12KB0.38KB▼ 66.40%