94% neptune-style-element

Code Review | Neptune Style Element

WordPress plugin Neptune Style Element scored 94% from 54 tests.

About plugin

  • Plugin page: neptune-style-ele...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress version: 5.8.1
  • First release: Dec 17, 2017
  • Latest release: Jan 17, 2018
  • Number of updates: 10
  • Update frequency: every 3.1 days
  • Top authors: neptunetheme (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

60+ active / 896 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.12MB] [CPU: ▼166.68ms] Passed 4 tests

This is a short check of server-side resources used by Neptune Style Element
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.70 ▲0.8731.82 ▲0.88
Dashboard /wp-admin3.17 ▲0.1249.27 ▲4.40
Posts /wp-admin/edit.php3.28 ▲0.1745.78 ▲5.06
Add New Post /wp-admin/post-new.php5.53 ▲0.1090.37 ▼667.21
Media Library /wp-admin/upload.php3.11 ▲0.1132.88 ▼4.77

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 18 new files
Database: no new tables, 1 new option
New WordPress options
neptune-style-element

Browser metrics Passed 4 tests

A check of browser resources used by Neptune Style Element
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,706 ▲11015.91 ▲0.197.96 ▼2.8950.71 ▲0.50
Dashboard /wp-admin2,986 ▲556.07 ▼0.11153.38 ▲8.82106.15 ▼1.44
Posts /wp-admin/edit.php2,759 ▲202.72 ▲0.0066.30 ▲3.0090.31 ▼0.55
Add New Post /wp-admin/post-new.php1,696 ▼1,99718.73 ▲3.62381.12 ▼51.53108.58 ▲1.62
Media Library /wp-admin/upload.php1,830 ▲205.01 ▼0.04142.92 ▼11.75123.83 ▼4.13

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests 75% 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 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
Please take a closer look at the following
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/neptune-style-element/inc/config.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Customize_Control' not found in wp-content/plugins/neptune-style-element/inc/class-neptune-style-element-font-family-control.php:6

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 88% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Tags: Please reduce the number of tags, currently 14 tag instead of maximum 10
  • Screenshots: Add an image for screenshot #1 (Customizer panel)
The official readme.txt might help

neptune-style-element/neptune-style-element.php Passed 13 tests

The main PHP script in "Neptune Style Element" version 1.0 is automatically included on every request by WordPress
40 characters long description:
Easy customize element for your website.

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
Success! There were no dangerous files found in this plugin1,675 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP9932641,366
JavaScript45953207
CSS330102

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity8.29
▷ Minimum class complexity3.00
▷ Maximum class complexity27.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods34
▷ Static methods38.82%
▷ Public methods2470.59%
▷ Protected methods1029.41%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG files were detected