10% marketengine

Code Review | MarketEngine

WordPress plugin MarketEngine scored10%from 54 tests.

About plugin

  • Plugin page: marketengine
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-4.7
  • WordPress version: 6.3.1
  • First release: Feb 15, 2017
  • Latest release: Feb 23, 2017
  • Number of updates: 30
  • Update frequency: every 0.3 days
  • Top authors: Enginethemes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,737 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Please fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Warning in wp-content/plugins/marketengine/marketengine.php+149
    require_once(wp-content/plugins/marketengine/includes/resolution/index.php): failed to open stream: No such file or directory

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

A check of server-side resources used by MarketEngine
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0033.82 ▼6.37
Dashboard /wp-admin3.31 ▲0.0045.32 ▼0.00
Posts /wp-admin/edit.php3.36 ▲0.0046.03 ▼4.32
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.20 ▼27.10
Media Library /wp-admin/upload.php3.23 ▲0.0032.18 ▼0.44

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 334 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for MarketEngine
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲7913.22 ▼1.164.34 ▲2.5939.58 ▼4.99
Dashboard /wp-admin2,209 ▲215.90 ▲1.08110.11 ▲3.6638.34 ▼2.17
Posts /wp-admin/edit.php2,089 ▼32.06 ▲0.0639.85 ▼0.9732.23 ▼2.35
Add New Post /wp-admin/post-new.php1,514 ▼323.44 ▲5.91650.65 ▲50.2054.50 ▲5.08
Media Library /wp-admin/upload.php1,382 ▼34.18 ▲0.0197.52 ▲0.1041.57 ▲0.32

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% 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
The following issues need your attention
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/marketengine/templates/inquiry/load-message-button.php
    • > /wp-content/plugins/marketengine/templates/organization.php
  • 123× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Notice
      Trying to get property 'post_status' of non-object in wp-content/plugins/marketengine/templates/resolution/dispute-button.php on line 8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/marketengine/templates/checkout/cancel-payment.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post() in wp-content/plugins/marketengine/templates/emails/receive-comment.php:3
    • > PHP Notice
      Undefined variable: order in wp-content/plugins/marketengine/templates/purchases/order.php on line 2
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/marketengine/tests/session/test-me-session.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/marketengine/templates/custom-fields/listing-form/field-label.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function marketengine_get_listing_types() in wp-content/plugins/marketengine/templates/post-listing/type.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/marketengine/tests/inquiry/test-me-inquiry-handle.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/marketengine/tests/query/test-me-query.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/marketengine/tests/message/test-me-insert-message.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
8 plugin tags: multi seller, niche, listing, commission, paypal gateway...

marketengine/marketengine.php 77% from 13 tests

This is the main PHP file of "MarketEngine" version 1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Domain Path: The domain path should be prefixed with a forward slash character ("/enginethemes")
  • Description: The description should be shorter than 140 characters (currently 264 characters long)
  • Domain Path: The domain path should use only dashes and lowercase characters ("enginethemes")

Code Analysis 97% from 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 plugin23,626 lines of code in 318 files:
LanguageFilesBlank linesComment linesLines of code
PHP2883,8238,87020,760
JavaScript212772032,074
CSS845115729
SVG10063

PHP code 50% from 2 tests

This plugin's cyclomatic complexity and code structure detailed below
It is recommended to fix the following
  • Please reduce cyclomatic complexity of methods to less than 100 (currently 185)
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity13.12
▷ Minimum class complexity1.00
▷ Maximum class complexity270.00
Average method complexity2.44
▷ Minimum method complexity1.00
▷ Maximum method complexity185.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes101
▷ Abstract classes43.96%
▷ Concrete classes9796.04%
▷ Final classes11.03%
Methods854
▷ Static methods15818.50%
▷ Public methods70882.90%
▷ Protected methods11613.58%
▷ Private methods303.51%
Functions209
▷ Named functions209100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 0% from 2 tests

Image compression 0% from 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
6 PNG files occupy 0.50MB with 0.38MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
sample-data/images/avatar-1.png72.33KB29.15KB▼ 59.69%
(invalid) sample-data/images/avatar-2.png153.22KB0.00KB▼ 100.00%
sample-data/images/avatar-4.png139.75KB38.88KB▼ 72.18%
assets/img/post-listing-none.png25.58KB3.96KB▼ 84.54%
sample-data/images/avatar-3.png61.71KB20.88KB▼ 66.16%