83% qanva-time-controlled-display

Code Review | Qanva Timecontrolled Display for Elementor

WordPress plugin Qanva Timecontrolled Display for Elementor scored83%from 54 tests.

About plugin

  • Plugin page: qanva-time-contro...
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.0-6.3.1
  • WordPress version: 6.3.1
  • First release: May 30, 2022
  • Latest release: Aug 31, 2023
  • Number of updates: 15
  • Update frequency: every 30.7 days
  • Top authors: workbenchwtf (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /557 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.08MB] [CPU: ▼0.49ms] Passed 4 tests

Analyzing server-side resources used by Qanva Timecontrolled Display for Elementor
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0842.40 ▼6.23
Dashboard /wp-admin3.38 ▲0.0858.33 ▲6.93
Posts /wp-admin/edit.php3.49 ▲0.1450.69 ▼2.02
Add New Post /wp-admin/post-new.php5.96 ▲0.0799.87 ▲4.33
Media Library /wp-admin/upload.php3.30 ▲0.0739.28 ▲1.95

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 31 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_recent-comments
qanva_qtcd_times
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Qanva Timecontrolled Display for Elementor
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲4514.29 ▼0.331.73 ▼0.4944.22 ▼2.41
Dashboard /wp-admin2,215 ▲385.62 ▲0.0593.85 ▼8.4845.90 ▲2.79
Posts /wp-admin/edit.php2,117 ▲172.02 ▲0.0837.55 ▲0.8136.15 ▼0.98
Add New Post /wp-admin/post-new.php1,547 ▲2117.99 ▼4.89642.83 ▲8.3275.27 ▲12.56
Media Library /wp-admin/upload.php1,417 ▲174.15 ▼0.11102.12 ▲1.5746.39 ▲2.56

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
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • qanva_qtcd_times
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however this is by no means an exhaustive test

SRP 50% 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
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/qanva-time-controlled-display/makecss.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_enqueue_style() in wp-content/plugins/qanva-time-controlled-display/admin/help.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 90% 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 need to be fixed:
  • Requires php: Version format is invalid
The official readme.txt might help

qanva-time-controlled-display/qanva-time-controlled-display.php 85% from 13 tests

This is the main PHP file of "Qanva Timecontrolled Display for Elementor" version 1.0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Domain Path: You should use only dashes and lowercase characters for the domain path ("languages")
  • Domain Path: The domain path should be prefixed with a forward slash character ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin1,573 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP47654738
JavaScript46134414
PO File1412986206
CSS7520148
SVG30167

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.47
Average class complexity16.50
▷ Minimum class complexity6.00
▷ Maximum class complexity27.00
Average method complexity2.41
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods22
▷ Static methods29.09%
▷ Public methods22100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants133.33%
▷ Class constants266.67%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
9 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/hidden.png2.35KB1.69KB▼ 28.19%
css/images/ui-icons_222222_256x240.png6.86KB4.18KB▼ 39.05%
css/images/ui-icons_2e83ff_256x240.png4.51KB4.18KB▼ 7.28%
img/visible.png2.14KB1.59KB▼ 25.69%
css/images/ui-icons_454545_256x240.png6.92KB4.18KB▼ 39.61%