89% nft-marketplace

Code Review | NFT Marketplace and Loyalty Rewards

WordPress plugin NFT Marketplace and Loyalty Rewards scored89%from 54 tests.

About plugin

  • Plugin page: nft-marketplace
  • Plugin version: 3.0.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3
  • WordPress version: 6.3.1
  • First release: Oct 13, 2022
  • Latest release: Sep 12, 2023
  • Number of updates: 11
  • Update frequency: every 30.5 days
  • Top authors: n1t1ngupta0301 (63.64%)prashantbhivsane (36.36%)shubhangigulve (18.18%)

Code review

54 tests

User reviews

1 review

Install metrics

50+ active /1,563 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲0.13MB] [CPU: ▲1.19ms] Passed 4 tests

An overview of server-side resources used by NFT Marketplace and Loyalty Rewards
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.60 ▲0.1342.85 ▲8.60
Dashboard /wp-admin3.43 ▲0.1350.23 ▼2.22
Posts /wp-admin/edit.php3.49 ▲0.1353.29 ▲5.65
Add New Post /wp-admin/post-new.php6.03 ▲0.1593.11 ▼2.75
Media Library /wp-admin/upload.php3.36 ▲0.1339.05 ▲4.08

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 85 new files
Database: no new tables, 8 new options
New WordPress options
widget_recent-posts
can_compress_scripts
monft_profile_page_id
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
monft_marketplace_page_id
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for NFT Marketplace and Loyalty Rewards
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,837 ▲7614.35 ▲0.031.94 ▲0.0531.16 ▼12.99
Dashboard /wp-admin2,221 ▲415.93 ▲0.2587.86 ▼3.6982.04 ▲41.73
Posts /wp-admin/edit.php2,120 ▲172.16 ▲0.2135.40 ▼5.1735.72 ▼2.99
Add New Post /wp-admin/post-new.php1,701 ▲17522.47 ▼1.16675.08 ▼28.6969.39 ▲12.52
Media Library /wp-admin/upload.php1,420 ▲204.25 ▲0.06107.07 ▼6.0285.97 ▲38.85

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 8 options
    • monft_marketplace_page_id
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • monft_profile_page_id
    • widget_recent-posts
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% 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
Attributes that need to be fixed:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (NFT Marketplace Configuration), #2 (Import NFT Collection), #3 (Minting NFTs), #4 (Listing NFTs), #5 (Buying NFTs), #6 (FAQs)
You can look at the official readme.txt

nft-marketplace/miniorange-nft-marketplace-settings.php 92% from 13 tests

The primary PHP file in "NFT Marketplace and Loyalty Rewards" version 3.0.0 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("nft-marketplace.php" instead of "miniorange-nft-marketplace-settings.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
No dangerous file extensions were detected4,203 lines of code in 47 files:
LanguageFilesBlank linesComment linesLines of code
PHP264571,2353,742
JSON100422
SVG60019
JavaScript935315
CSS5065

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity18.18
▷ Minimum class complexity1.00
▷ Maximum class complexity68.00
Average method complexity3.89
▷ Minimum method complexity1.00
▷ Maximum method complexity64.00
Code structure
Namespaces5
Interfaces0
Traits0
Classes22
▷ Abstract classes00.00%
▷ Concrete classes22100.00%
▷ Final classes00.00%
Methods131
▷ Static methods32.29%
▷ Public methods12696.18%
▷ Protected methods00.00%
▷ Private methods53.82%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants38
▷ Global constants37.89%
▷ Class constants3592.11%
▷ Public constants35100.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
9 PNG files occupy 0.11MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
classes/resources/images/support3.png2.49KB2.11KB▼ 15.28%
classes/resources/images/metamask.png10.00KB10.42KB0.00%
classes/resources/images/miniorange.png0.44KB0.35KB▼ 18.61%
classes/resources/images/add-nft-details.png4.45KB2.37KB▼ 46.62%
classes/resources/images/flags16.png61.80KB19.90KB▼ 67.79%