10% iota-pay-per-content

Code Review | Iota Pay Per Content

WordPress plugin Iota Pay Per Content scored10%from 54 tests.

About plugin

  • Plugin page: iota-pay-per-content
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.2.1
  • WordPress version: 6.3.1
  • First release: Jun 6, 2019
  • Latest release: Jun 6, 2019
  • Number of updates: 6
  • Update frequency: every 0.3 days
  • Top authors: 019mrb (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /532 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
These installer errors require your attention
  • Install procedure had errors
    • > Warning in wp-content/plugins/iota-pay-per-content/index.php+22
    require_once(wp-content/plugins/iota-ppc-wp-plugin/lib/trytes/Trytes.php): failed to open stream: No such file or directory

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.10ms] Passed 4 tests

Analyzing server-side resources used by Iota Pay Per Content
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0045.03 ▲5.94
Dashboard /wp-admin3.31 ▲0.0051.61 ▲1.32
Posts /wp-admin/edit.php3.36 ▲0.0046.87 ▼5.78
Add New Post /wp-admin/post-new.php5.89 ▲0.0079.29 ▼25.86
Media Library /wp-admin/upload.php3.23 ▲0.0045.17 ▲8.95

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Iota Pay Per Content
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.59 ▲0.101.87 ▼0.4144.04 ▲3.65
Dashboard /wp-admin2,195 ▲185.63 ▼0.0298.77 ▲7.2943.35 ▲1.90
Posts /wp-admin/edit.php2,100 ▼01.96 ▼0.0635.47 ▼6.2334.36 ▼5.21
Add New Post /wp-admin/post-new.php1,528 ▼923.01 ▲4.78636.64 ▲9.0162.90 ▼7.11
Media Library /wp-admin/upload.php1,400 ▲34.22 ▲0.01111.32 ▲7.4346.23 ▲0.63

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
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts

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
The smoke test was a success, however most plugin functionality was not tested

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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
7 plugin tags: ppc, payment, read, blog, decentralised...

iota-pay-per-content/index.php 92% from 13 tests

The main file in "Iota Pay Per Content" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("iota-pay-per-content.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected725 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP3122101548
JavaScript2712132
CSS18045

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity3.00
▷ Minimum class complexity1.00
▷ Maximum class complexity5.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods5
▷ Static methods240.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions26
▷ Named functions1350.00%
▷ Anonymous functions1350.00%
Constants6
▷ Global constants466.67%
▷ Class constants233.33%
▷ Public constants2100.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
PNG images were not found in this plugin