58% profitshare

Code Review | Emag Profitshare

WordPress plugin Emag Profitshare scored58%from 54 tests.

About plugin

  • Plugin page: profitshare
  • Plugin version: 2.0.9
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.5
  • WordPress version: 6.3.1
  • First release: Mar 16, 2011
  • Latest release: Jul 16, 2013
  • Number of updates: 23
  • Update frequency: every 37.1 days
  • Top authors: iamntz (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,146 total downloads

Benchmarks

Plugin footprint 48% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▼1.20MB] [CPU: ▼48.23ms] Passed 4 tests

Analyzing server-side resources used by Emag Profitshare
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.78 ▼0.6813.74 ▼26.57
Dashboard /wp-admin2.82 ▼0.5318.40 ▼47.55
Posts /wp-admin/edit.php2.82 ▼0.5418.27 ▼31.31
Add New Post /wp-admin/post-new.php2.82 ▼3.0716.95 ▼87.49
Media Library /wp-admin/upload.php2.82 ▼0.4116.73 ▼15.21
Setări Profitshare /wp-admin/options-general.php?page=profitshare/index.php2.8215.57

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 2 new files
Database: 1 new table, 7 new options
New tables
wp_ntz_referral
New WordPress options
ntz_referral_version
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Emag Profitshare
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.23 ▼1.011.73 ▼0.1840.33 ▼3.81
Dashboard /wp-admin2,213 ▲254.83 ▼0.26103.08 ▼4.8741.33 ▼5.94
Posts /wp-admin/edit.php2,093 ▲42.00 ▼0.0139.55 ▲2.1935.91 ▲0.39
Add New Post /wp-admin/post-new.php1,517 ▼1617.53 ▼5.71675.11 ▲71.2963.57 ▲9.80
Media Library /wp-admin/upload.php1,392 ▲14.28 ▲0.0796.95 ▲1.4742.67 ▼1.48
Setări Profitshare /wp-admin/options-general.php?page=profitshare/index.php8922.0225.3141.80

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Uninstall procedure validation failed for this plugin
    • > Notice in wp-content/plugins/profitshare/index.php+58
    Undefined index: quick_generator
  • Zombie tables were found after uninstall: 1 table
    • wp_ntz_referral
  • Zombie WordPress options were found after uninstall: 7 options
    • can_compress_scripts
    • theysaidso_admin_options
    • ntz_referral_version
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=profitshare/index.php
    • > Notice in wp-content/plugins/profitshare/index.php+58
    Undefined index: quick_generator
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=profitshare/index.php
    • > Notice in wp-content/plugins/profitshare/index.php+185
    Undefined index: short_links
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=profitshare/index.php
    • > Notice in wp-content/plugins/profitshare/index.php+233
    Trying to access array offset on value of type bool

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 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/profitshare/index.php:433

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that require attention:
  • Contributors: The plugin contributors field is missing
You can look at the official readme.txt

profitshare/index.php 92% from 13 tests

"Emag Profitshare" version 2.0.9's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("profitshare.php" instead of "index.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
There were no executable files found in this plugin359 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP14827359

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity39.00
▷ Minimum class complexity39.00
▷ Maximum class complexity39.00
Average method complexity4.45
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods00.00%
▷ Public methods11100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
No PNG images were found in this plugin