78% dresslikeme

Code Review | DressLikeMe

WordPress plugin DressLikeMe scored78%from 54 tests.

About plugin

  • Plugin page: dresslikeme
  • Plugin version: 1.2
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.1-4.9.4
  • WordPress version: 6.3.1
  • First release: Dec 22, 2017
  • Latest release: Feb 23, 2018
  • Number of updates: 14
  • Update frequency: every 4.5 days
  • Top authors: dresslikeme (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /918 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.17MB] [CPU: ▼3.91ms] Passed 4 tests

This is a short check of server-side resources used by DressLikeMe
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.65 ▲0.1941.23 ▼1.60
Dashboard /wp-admin3.47 ▲0.1650.30 ▼4.12
Posts /wp-admin/edit.php3.59 ▲0.2255.66 ▲4.45
Add New Post /wp-admin/post-new.php6.05 ▲0.1688.09 ▼14.38
Media Library /wp-admin/upload.php3.39 ▲0.1643.28 ▲7.92

Server storage [IO: ▲0.14MB] [DB: ▲0.00MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
It is recommended to fix the following issues
  • Illegal file modification detected: 1 file (4.00KB) outside of "wp-content/plugins/dresslikeme/" and "wp-content/uploads/"
    • (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
Filesystem: 38 new files
Database: no new tables, 10 new options
New WordPress options
widget_dlm_profile_widget
widget_recent-comments
widget_dlm_outfit_widget
widget_dlm_wardrobe_widget
can_compress_scripts
theysaidso_admin_options
widget_dlm_outfits_widget
widget_recent-posts
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for DressLikeMe
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,938 ▲15213.57 ▼0.994.80 ▲2.7638.87 ▼4.05
Dashboard /wp-admin2,240 ▲344.89 ▼1.0198.41 ▼8.7376.49 ▲35.28
Posts /wp-admin/edit.php2,125 ▲252.02 ▲0.0239.16 ▲2.2035.52 ▼0.84
Add New Post /wp-admin/post-new.php1,548 ▲2223.58 ▲6.20678.54 ▼13.7264.85 ▲7.85
Media Library /wp-admin/upload.php1,416 ▲134.19 ▼0.04104.80 ▲1.7375.18 ▲27.47

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
Please fix the following items
  • This plugin did not uninstall successfully, leaving 10 options in the database
    • widget_dlm_outfits_widget
    • widget_dlm_wardrobe_widget
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_dlm_profile_widget
    • widget_recent-posts
    • widget_dlm_outfit_widget
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Good news, no errors were detected

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 5× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/dresslikeme/views/tinymce-profile.php
    • > /wp-content/plugins/dresslikeme/views/tinymce-product.php
    • > /wp-content/plugins/dresslikeme/views/tinymce-wardrobe.php
    • > /wp-content/plugins/dresslikeme/views/tinymce-outfits.php
    • > /wp-content/plugins/dresslikeme/views/tinymce-outfit.php
  • 14× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/dresslikeme/views/admin-head.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'TlView' not found in wp-content/plugins/dresslikeme/class.plugin.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/dresslikeme/views/script-product.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/dresslikeme/views/script-profile.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/dresslikeme/widgets/dlm_widgets.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/dresslikeme/views/settings.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/dresslikeme/views/script-outfit.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/dresslikeme/views/script-wardrobe.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'dlm_widgets' not found in wp-content/plugins/dresslikeme/widgets/dlm_profile_widget.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'dlm_widgets' not found in wp-content/plugins/dresslikeme/widgets/dlm_outfit_widget.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention:
  • Plugin Name: Please specify the plugin name on the first line ( === dresslikeme === )
You can look at the official readme.txt

dresslikeme/dresslikeme.php Passed 13 tests

The main PHP file in "DressLikeMe" ver. 1.2 adds more information about the plugin and also serves as the entry point for this plugin
92 characters long description:
Get inspired by the worldwide most popular fashion trends and publish your favourite outfit.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected2,409 lines of code in 29 files:
LanguageFilesBlank linesComment linesLines of code
PHP20236261,395
PO File5292304807
JavaScript1400196
CSS22110
YAML1001

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity10.29
▷ Minimum class complexity5.00
▷ Maximum class complexity24.00
Average method complexity2.41
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods46
▷ Static methods00.00%
▷ Public methods3678.26%
▷ Protected methods510.87%
▷ Private methods510.87%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/dlm-wp-logo.png0.50KB0.51KB0.00%