77% islamic-duood-sharief

Code Review | Islamic Durood Sharief

WordPress plugin Islamic Durood Sharief scored 77% from 54 tests.

About plugin

  • Plugin page: islamic-duood-sha...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-4.9
  • WordPress version: 6.3.1
  • First release: Nov 21, 2018
  • Latest release: Nov 21, 2018
  • Number of updates: 3
  • Update frequency: N/A
  • Top authors: samiullah-kaifi (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 801 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.15MB] [CPU: ▼1.29ms] Passed 4 tests

A check of server-side resources used by Islamic Durood Sharief
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1537.52 ▼4.94
Dashboard /wp-admin3.45 ▲0.1545.95 ▼0.59
Posts /wp-admin/edit.php3.50 ▲0.1447.78 ▲1.57
Add New Post /wp-admin/post-new.php6.04 ▲0.1593.47 ▼0.85
Media Library /wp-admin/upload.php3.37 ▲0.1435.78 ▲1.23
Durood Sharief FD /wp-admin/edit.php?post_type=durood_sharief_fd3.4438.34
Add New /wp-admin/post-new.php?post_type=durood_sharief_fd3.5145.77

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 9 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Islamic Durood Sharief
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,931 ▲19613.75 ▼0.635.53 ▲3.8040.50 ▼0.74
Dashboard /wp-admin2,240 ▲524.91 ▲0.00108.04 ▼8.7141.34 ▲1.07
Posts /wp-admin/edit.php2,119 ▲252.08 ▲0.0341.51 ▲1.0933.79 ▼0.18
Add New Post /wp-admin/post-new.php1,543 ▲1017.74 ▼5.39588.88 ▼57.6255.51 ▼13.81
Media Library /wp-admin/upload.php1,425 ▲344.37 ▲0.20104.40 ▲8.5544.29 ▼0.33
Durood Sharief FD /wp-admin/edit.php?post_type=durood_sharief_fd1,2833.6957.9126.92
Add New /wp-admin/post-new.php?post_type=durood_sharief_fd3,3677.43203.81147.29

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/islamic-duood-sharief/duroodshariefdiv-floatingdiv.php:12

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please fix the following user-side errors
    • > GET request to /wp-admin/post-new.php?post_type=durood_sharief_fd
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,wp-polyfill-inert,regenerator-runtime,wp-polyfill,wp-hooks&ver=6.3.1 1:28609 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-admin/post-new.php?post_type=durood_sharief_fd:439:34)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,wp-polyfill-inert,regenerator-runtime,wp-polyfill,wp-hooks&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,wp-polyfill-inert,regenerator-runtime,wp-polyfill,wp-hooks&ver=6.3.1:2:27292)" undefined
    • > GET request to /wp-admin/post-new.php?post_type=durood_sharief_fd
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,wp-polyfill-inert,regenerator-runtime,wp-polyfill,wp-hooks&ver=6.3.1 1:28609 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-admin/post-new.php?post_type=durood_sharief_fd:887:31)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,wp-polyfill-inert,regenerator-runtime,wp-polyfill,wp-hooks&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,wp-polyfill-inert,regenerator-runtime,wp-polyfill,wp-hooks&ver=6.3.1:2:27292)" undefined
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=durood_sharief_fd
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,wp-polyfill-inert,regenerator-runtime,wp-polyfill,wp-hooks&ver=6.3.1 1:28721 Uncaught TypeError: $(...).live is not a function

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Tags: There are too many tags (39 tag instead of maximum 10)
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Display Front End.), #2 (Display Backend.), #3 (Display Setting & Data.)
You can look at the official readme.txt

islamic-duood-sharief/duroodshariefdiv-floatingdiv.php 85% from 13 tests

"Islamic Durood Sharief" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("islamic-duood-sharief.php" instead of "duroodshariefdiv-floatingdiv.php")
  • Description: Please don't use more than 140 characters for the plugin description (currently 172 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin1,234 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP114115967
CSS2633236
JavaScript2141331

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.29
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%
Functions20
▷ Named functions20100.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
3 PNG files occupy 0.31MB with 0.21MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-3.png70.22KB22.76KB▼ 67.59%
screenshot-2.png216.30KB65.29KB▼ 69.82%
screenshot-1.png27.87KB9.50KB▼ 65.90%