84% gallery-openseanft

Code Review | Opensea NFT Gallery

WordPress plugin Opensea NFT Gallery scored84%from 54 tests.

About plugin

  • Plugin page: gallery-openseanft
  • Plugin version: 1.1.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3.2-6.2.2
  • WordPress version: 6.3.1
  • First release: Jan 27, 2023
  • Latest release: Jun 20, 2023
  • Number of updates: 49
  • Update frequency: every 3.0 days
  • Top authors: techforceglobal (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /387 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.11MB] [CPU: ▼3.82ms] Passed 4 tests

An overview of server-side resources used by Opensea NFT Gallery
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1138.12 ▼6.77
Dashboard /wp-admin3.42 ▲0.1247.48 ▼2.36
Posts /wp-admin/edit.php3.47 ▲0.1148.64 ▼5.17
Add New Post /wp-admin/post-new.php6.02 ▲0.13101.64 ▼0.15
Media Library /wp-admin/upload.php3.34 ▲0.1135.99 ▼0.96
Setting /wp-admin/admin.php?page=gallery-setting3.3256.77
Gallery OpenseaNFT /wp-admin/admin.php?page=gallery-openseanft3.3432.43

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 52 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Opensea NFT Gallery
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,872 ▲12613.34 ▼1.031.77 ▼0.0731.09 ▼13.74
Dashboard /wp-admin2,253 ▲655.93 ▲1.06112.07 ▲5.0344.55 ▼0.38
Posts /wp-admin/edit.php2,143 ▲542.47 ▲0.4540.05 ▼0.5039.42 ▲4.04
Add New Post /wp-admin/post-new.php1,565 ▲3523.49 ▲5.22682.03 ▲29.7657.43 ▼0.46
Media Library /wp-admin/upload.php1,438 ▲504.31 ▲0.1397.85 ▼7.9346.42 ▼1.11
Setting /wp-admin/admin.php?page=gallery-setting1,1081.8633.5746.24
Gallery OpenseaNFT /wp-admin/admin.php?page=gallery-openseanft1,1851.9328.5341.87

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 75% 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 | 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
  • 3× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/gallery-openseanft/gallery-openseanft.php:38
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/gallery-openseanft/user_verifykey.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/gallery-openseanft/generatekey.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% 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
These attributes need to be fixed:
  • Donate link: Please fix this invalid URI: "none"
The official readme.txt might help

gallery-openseanft/gallery-openseanft.php 92% from 13 tests

The principal PHP file in "Opensea NFT Gallery" v. 1.1.0 is loaded by WordPress automatically on each request
The following require your attention:
  • Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase

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 plugin15,343 lines of code in 32 files:
LanguageFilesBlank linesComment linesLines of code
CSS134,5418710,613
SVG3012,837
PHP419556920
JSON100690
JavaScript1185142283

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.08
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%
Functions14
▷ Named functions14100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
3 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/image/india.png1.51KB0.73KB▼ 51.62%
assets/image/us.png2.23KB1.14KB▼ 48.91%
assets/image/user.png3.97KB2.46KB▼ 38.12%