74% mamurjor-simple-contact-form

Code Review | mamurjor simple contact form

WordPress plugin mamurjor simple contact form scored74%from 54 tests.

About plugin

  • Plugin page: mamurjor-simple-c...
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.9
  • WordPress version: 6.3.1
  • First release: Apr 30, 2020
  • Latest release: May 6, 2020
  • Number of updates: 6
  • Update frequency: every 1.0 days
  • Top authors: mamurjor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /406 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼4.96ms] Passed 4 tests

A check of server-side resources used by mamurjor simple contact form
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0741.30 ▼2.44
Dashboard /wp-admin3.37 ▲0.0755.69 ▲0.91
Posts /wp-admin/edit.php3.48 ▲0.1350.69 ▲0.87
Add New Post /wp-admin/post-new.php5.97 ▲0.0888.21 ▼16.10
Media Library /wp-admin/upload.php3.29 ▲0.0636.82 ▼2.16

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 24 new files
Database: 1 new table, 6 new options
New tables
wp_mamurjor_contact
New WordPress options
db_upgraded
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for mamurjor simple contact form
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,903 ▲15713.57 ▼0.677.92 ▲5.8440.55 ▼7.73
Dashboard /wp-admin2,226 ▲384.97 ▼0.91103.06 ▼15.4839.91 ▼4.02
Posts /wp-admin/edit.php2,109 ▲202.01 ▲0.0136.71 ▼7.6432.80 ▼1.16
Add New Post /wp-admin/post-new.php1,540 ▲718.34 ▼4.71611.10 ▼66.1056.56 ▲0.78
Media Library /wp-admin/upload.php1,408 ▲234.23 ▲0.01100.44 ▼4.7048.52 ▲2.20

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • The uninstall procedure failed, leaving 1 table in the database
    • wp_mamurjor_contact
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments

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
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 2× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/mamurjor-simple-contact-form/admin/partials/mamurjor_simple_contact_form-admin-display.php
    • > /wp-content/plugins/mamurjor-simple-contact-form/public/partials/mamurjor_simple_contact_form-public-display.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
6 plugin tags: admin, form, info, show, contact...

mamurjor-simple-contact-form/mamurjor_simple_contact_form.php 85% from 13 tests

The principal PHP file in "mamurjor simple contact form" v. 1.0.0 is loaded by WordPress automatically on each request
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("mamurjor-simple-contact-form.php" instead of "mamurjor_simple_contact_form.php")
  • Text Domain: The text domain should only use lowercase characters and dashes

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
Good job! No executable or dangerous file extensions detected323 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP15191535317
JavaScript24546
CSS2080

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.11
Average class complexity1.43
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.13
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods23
▷ Static methods28.70%
▷ Public methods1878.26%
▷ Protected methods00.00%
▷ Private methods521.74%
Functions7
▷ Named functions7100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
PNG images were not found in this plugin