83% kosmos-esync-dashboard-connector

Code Review | Kosmos eSync Dashboard Connector

WordPress plugin Kosmos eSync Dashboard Connector scored83%from 54 tests.

About plugin

  • Plugin page: kosmos-esync-dash...
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.0-5.1
  • WordPress version: 6.3.1
  • First release: Aug 31, 2017
  • Latest release: Mar 23, 2023
  • Number of updates: 6
  • Update frequency: every 339.2 days
  • Top authors: kosmoscentral (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

100+ active /2,519 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

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

A check of server-side resources used by Kosmos eSync Dashboard Connector
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0035.42 ▼5.64
Dashboard /wp-admin3.31 ▲0.0045.12 ▼3.44
Posts /wp-admin/edit.php3.36 ▲0.0047.39 ▼0.20
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.83 ▼9.87
Media Library /wp-admin/upload.php3.23 ▲0.0034.82 ▲1.53

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Kosmos eSync Dashboard Connector
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲4313.28 ▼1.161.90 ▼0.0846.14 ▲3.42
Dashboard /wp-admin2,206 ▲184.86 ▼0.05107.48 ▼9.0642.28 ▼2.87
Posts /wp-admin/edit.php2,089 ▼02.04 ▼0.0139.01 ▲2.5235.97 ▲2.16
Add New Post /wp-admin/post-new.php1,542 ▼018.55 ▲0.18597.21 ▼54.9858.94 ▲7.22
Media Library /wp-admin/upload.php1,388 ▼04.39 ▲0.1894.35 ▼0.8042.13 ▼0.69

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
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 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
Please fix the following items
  • 3× PHP files output text when accessed directly:
    • > /wp-content/plugins/kosmos-esync-dashboard-connector/public/partials/ked-connector-public-display.php
    • > /wp-content/plugins/kosmos-esync-dashboard-connector/admin/partials/ked-connector-admin-display.php
    • > /wp-content/plugins/kosmos-esync-dashboard-connector/settings/settings.php

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that need to be fixed:
  • Tags: You are using too many tags: 13 tag instead of maximum 10
You can look at the official readme.txt

kosmos-esync-dashboard-connector/ked-connector.php 85% from 13 tests

The entry point to "Kosmos eSync Dashboard Connector" version 1.0.1 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Requires at least: The required version number must match the one declared in readme.txt ("4.0" instead of "3.0.0")
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("kosmos-esync-dashboard-connector.php" instead of "ked-connector.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
No dangerous file extensions were detected524 lines of code in 18 files:
LanguageFilesBlank linesComment linesLines of code
PHP14177668484
CSS27932
JavaScript28548

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity7.50
▷ Minimum class complexity1.00
▷ Maximum class complexity51.00
Average method complexity2.49
▷ Minimum method complexity1.00
▷ Maximum method complexity31.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods35
▷ Static methods25.71%
▷ Public methods2982.86%
▷ Protected methods00.00%
▷ Private methods617.14%
Functions12
▷ Named functions12100.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
4 PNG files occupy 0.06MB with 0.02MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
public/images/rs-banner.png48.84KB22.35KB▼ 54.25%
public/images/kosmos_icon.png3.06KB1.71KB▼ 43.97%
public/images/kosmos_icon_small.png0.57KB0.50KB▼ 10.86%
public/images/kosmos_logo.png6.32KB3.71KB▼ 41.31%