84% demomentsomtres-night-and-day

Code Review | DeMomentSomTres Night and Day

WordPress plugin DeMomentSomTres Night and Day scored 84% from 54 tests.

About plugin

  • Plugin page: demomentsomtres-n...
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.9.1
  • WordPress version: 6.3.1
  • First release: Mar 24, 2013
  • Latest release: May 20, 2014
  • Number of updates: 5
  • Update frequency: every 84.8 days
  • Top authors: marcqueralt (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 7,417 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼7.86ms] Passed 4 tests

Analyzing server-side resources used by DeMomentSomTres Night and Day
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0135.10 ▼9.86
Dashboard /wp-admin3.32 ▲0.0139.66 ▼11.69
Posts /wp-admin/edit.php3.37 ▲0.0148.08 ▲0.01
Add New Post /wp-admin/post-new.php5.90 ▲0.0193.88 ▼9.35
Media Library /wp-admin/upload.php3.24 ▲0.0135.66 ▼0.55

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by DeMomentSomTres Night and Day
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲9013.36 ▼1.021.82 ▲0.0738.61 ▼4.20
Dashboard /wp-admin2,209 ▲185.90 ▲1.02104.66 ▼3.3741.38 ▼3.62
Posts /wp-admin/edit.php2,089 ▼02.06 ▲0.0539.11 ▼3.0934.78 ▼0.79
Add New Post /wp-admin/post-new.php1,542 ▼018.51 ▲0.32607.45 ▲0.1356.74 ▲1.06
Media Library /wp-admin/upload.php1,388 ▼04.24 ▲0.0099.87 ▼12.8143.63 ▼4.08

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
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options

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
The smoke test was a success, however most plugin functionality was not tested

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
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/demomentsomtres-night-and-day/demomentsomtres-night-and-day.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
1 plugin tags: shortcode

demomentsomtres-night-and-day/demomentsomtres-night-and-day.php 92% from 13 tests

Analyzing the main PHP file in "DeMomentSomTres Night and Day" version 1.0.1
Please take the time to fix the following:
  • Description: The description should be shorter than 140 characters (currently 213 characters long)

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 detected36 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP142036

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.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 images were found in this plugin