84% demomentsomtres-franchise

Code Review | DeMomentSomTres Franquicia

WordPress plugin DeMomentSomTres Franquicia scored 84% from 54 tests.

About plugin

  • Plugin page: demomentsomtres-f...
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.4
  • WordPress version: 6.3.1
  • First release: Jul 15, 2015
  • Latest release: Nov 30, 2015
  • Number of updates: 5
  • Update frequency: every 34.2 days
  • Top authors: marcqueralt (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 646 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.35MB] [CPU: ▼0.96ms] Passed 4 tests

An overview of server-side resources used by DeMomentSomTres Franquicia
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.81 ▲0.3543.16 ▼1.99
Dashboard /wp-admin3.65 ▲0.3547.04 ▼0.23
Posts /wp-admin/edit.php3.77 ▲0.4150.39 ▲1.45
Add New Post /wp-admin/post-new.php6.24 ▲0.35101.05 ▼0.60
Media Library /wp-admin/upload.php3.58 ▲0.3537.90 ▼1.00
Install Plugins /wp-admin/themes.php?page=tgmpa-install-plugins3.5833.69
Add New /wp-admin/post-new.php?post_type=franchise-store3.7051.27
All Stores /wp-admin/edit.php?post_type=franchise-store3.6237.70

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for DeMomentSomTres Franquicia
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,877 ▲14213.79 ▼0.591.66 ▼0.2543.49 ▼8.46
Dashboard /wp-admin2,280 ▲924.86 ▼0.04108.35 ▼9.2345.19 ▼3.78
Posts /wp-admin/edit.php2,171 ▲852.16 ▲0.1542.26 ▲4.7542.78 ▲12.23
Add New Post /wp-admin/post-new.php1,594 ▲7523.12 ▼0.03626.28 ▼22.1052.10 ▼9.33
Media Library /wp-admin/upload.php1,461 ▲794.43 ▲0.2099.87 ▼2.4345.24 ▲1.21
Install Plugins /wp-admin/themes.php?page=tgmpa-install-plugins1,0202.2127.7727.04
Add New /wp-admin/post-new.php?post_type=franchise-store2,3187.58168.9070.60
All Stores /wp-admin/edit.php?post_type=franchise-store1,1411.9733.4534.19

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for 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 take a closer look at the following
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/demomentsomtres-franchise/lib/class-tgm-plugin-activation.php:161
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/demomentsomtres-franchise/lib/class-tgm-plugin-activation.php:161
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/demomentsomtres-franchise/lib/plugins/tgm-example-plugin/tgm-example-plugin.php:31
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/demomentsomtres-franchise/lib/class-tgm-plugin-activation.php:161

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
2 plugin tags: franchise manager, stores

demomentsomtres-franchise/demomentsomtres-franquicia.php 92% from 13 tests

The primary PHP file in "DeMomentSomTres Franquicia" version 1.0.1 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("demomentsomtres-franchise.php" instead of "demomentsomtres-franquicia.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected2,121 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP44459051,649
PO File1103127300
Markdown1500143
JSON10029

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity44.40
▷ Minimum class complexity10.00
▷ Maximum class complexity112.00
Average method complexity4.62
▷ Minimum method complexity1.00
▷ Maximum method complexity38.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods60
▷ Static methods11.67%
▷ Public methods5490.00%
▷ Protected methods610.00%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants19
▷ Global constants15.26%
▷ Class constants1894.74%
▷ Public constants18100.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
There were not PNG files found in your plugin