68% moredeal

Code Review | Moredeal - Monetize your WordPress content

WordPress plugin Moredeal - Monetize your WordPress content scored68%from 54 tests.

About plugin

  • Plugin page: moredeal
  • Plugin version: 2.0.25
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6.1-6.1.1
  • WordPress version: 6.3.1
  • First release: Dec 6, 2022
  • Latest release: Feb 6, 2023
  • Number of updates: 53
  • Update frequency: every 3.6 days
  • Top authors: df007df (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,313 total downloads

Benchmarks

Plugin footprint 65% 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.96MB] [CPU: ▲0.23ms] Passed 4 tests

An overview of server-side resources used by Moredeal - Monetize your WordPress content
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /4.37 ▲0.9143.25 ▼0.29
Dashboard /wp-admin4.27 ▲0.9755.55 ▲2.08
Posts /wp-admin/edit.php4.33 ▲0.9752.71 ▲1.19
Add New Post /wp-admin/post-new.php7.17 ▲1.2896.93 ▼2.08
Media Library /wp-admin/upload.php4.20 ▲0.9745.40 ▲7.92
Product /wp-admin/admin.php?page=moredeal-product4.7949.57
HotKeywords /wp-admin/admin.php?page=moredeal-hotKeywords-config4.4638.85
Templates /wp-admin/admin.php?page=moredeal-template-config4.4941.64
Setting /wp-admin/admin.php?page=moredeal4.4838.55
License /wp-admin/admin.php?page=moredeal-license4.4641.07

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 161 new files
Database: 1 new table, 14 new options
New tables
wp_moredeal_product
New WordPress options
can_compress_scripts
moredeal_options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
moredeal_modules_AmazonNoApi
widget_recent-comments
theysaidso_admin_options
moredeal_db_version
moredeal_modules_Amazon
...

Browser metrics Passed 4 tests

Moredeal - Monetize your WordPress content: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,836 ▲7514.34 ▼0.281.94 ▲0.1040.13 ▼2.40
Dashboard /wp-admin2,230 ▲505.56 ▼0.1083.23 ▼6.7771.19 ▲31.47
Posts /wp-admin/edit.php2,144 ▲411.98 ▲0.0135.21 ▼1.2434.17 ▼4.75
Add New Post /wp-admin/post-new.php2,299 ▲77326.85 ▲3.18827.44 ▲144.1783.19 ▲27.48
Media Library /wp-admin/upload.php1,438 ▲384.20 ▼0.01101.83 ▼8.2776.80 ▲27.63
Product /wp-admin/admin.php?page=moredeal-product1,1382.0426.2130.39
HotKeywords /wp-admin/admin.php?page=moredeal-hotKeywords-config9721.8534.1240.75
Templates /wp-admin/admin.php?page=moredeal-template-config3,0453.42119.9836.86
Setting /wp-admin/admin.php?page=moredeal1,5542.5952.4636.20
License /wp-admin/admin.php?page=moredeal-license9051.9431.1931.07

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • The plugin did not uninstall successfully, leaving 1 table in the database
    • wp_moredeal_product
  • The uninstall procedure has failed, leaving 13 options in the database
    • moredeal_template_options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • moredeal_hot_keywords_options
    • moredeal_modules_Amazon
    • moredeal_options
    • moredeal_modules_AmazonNoApi
    • widget_theysaidso_widget
    • widget_recent-comments
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
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 output text when accessed directly:
    • > /wp-content/plugins/moredeal/moredeal.php

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Please fix the following user-side errors
    • > GET request to /wp-admin/admin.php?page=moredeal-product
    • > Network (severe)
    wp-content/plugins/moredeal/res/img/moredeal_waiting.gif - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/admin.php?page=moredeal-product
    • > Network (severe)
    wp-content/plugins/moredeal/res/js/jquery.blockUI.js?ver=6.3.1 - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% 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
Attributes that require attention:
  • Tags: Too many tags (31 tag instead of maximum 10); only the first 5 tags are used in your directory listing
  • Screenshots: Add descriptions for screenshots #1, #10, #2, #3, #4, #5, #6 in moredeal/assets to your readme.txt
You can look at the official readme.txt

moredeal/moredeal.php 92% from 13 tests

The main PHP file in "Moredeal - Monetize your WordPress content" ver. 2.0.25 adds more information about the plugin and also serves as the entry point for this plugin
The following require your attention:
  • Description: Keep the plugin description shorter than 140 characters (currently 318 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin24,077 lines of code in 116 files:
LanguageFilesBlank linesComment linesLines of code
PHP681,7073,2249,941
CSS13355327,191
JavaScript299718625,515
PO File2527201,058
SVG300290
Vuejs Component15082

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.47
Average class complexity24.96
▷ Minimum class complexity1.00
▷ Maximum class complexity231.00
Average method complexity2.97
▷ Minimum method complexity1.00
▷ Maximum method complexity30.00
Code structure
Namespaces10
Interfaces1
Traits0
Classes51
▷ Abstract classes1019.61%
▷ Concrete classes4180.39%
▷ Final classes00.00%
Methods625
▷ Static methods26141.76%
▷ Public methods55789.12%
▷ Protected methods264.16%
▷ Private methods426.72%
Functions5
▷ Named functions240.00%
▷ Anonymous functions360.00%
Constants56
▷ Global constants58.93%
▷ Class constants5191.07%
▷ Public constants51100.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
29 PNG files occupy 0.13MB with 0.04MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
res/logos/amazon-it.png4.47KB3.13KB▼ 30.07%
res/logos/amazon-es.png4.47KB3.13KB▼ 30.07%
res/css/images/ui-bg_glass_75_dadada_1x400.png0.32KB0.16KB▼ 50.46%
res/colorbox/images/controls.png1.23KB1.28KB0.00%
res/logos/aliexpress-com.png5.75KB3.08KB▼ 46.47%