10% mz-mobilize-america-interface

Code Review | MZ Mobilize America Interface

WordPress plugin MZ Mobilize America Interface scored10%from 54 tests.

About plugin

  • Plugin page: mz-mobilize-ameri...
  • Plugin version: 1.0.3
  • PHP version: 7.4.16
  • WordPress compatibility: 5.3-5.7.1
  • WordPress version: 6.3.1
  • First release: Aug 27, 2020
  • Latest release: Apr 30, 2021
  • Number of updates: 12
  • Update frequency: every 20.4 days
  • Top authors: mikeill (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

20+ active /518 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
You still need to fix the following installer errors
  • Install procedure had errors
    • > Warning in wp-includes/class-wp-hook.php+310
    call_user_func_array() expects parameter 1 to be a valid callback, class 'MZ_Mobilize_America\\Core\Activator' not found

Server metrics [RAM: ▲0.44MB] [CPU: ▼6.19ms] Passed 4 tests

A check of server-side resources used by MZ Mobilize America Interface
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.92 ▲0.4639.03 ▼5.20
Dashboard /wp-admin3.81 ▲0.4647.44 ▼12.75
Posts /wp-admin/edit.php3.86 ▲0.5058.29 ▲10.27
Add New Post /wp-admin/post-new.php6.32 ▲0.4385.01 ▼11.02
Media Library /wp-admin/upload.php3.64 ▲0.4136.96 ▲4.23
MZ Mobilize America /wp-admin/options-general.php?page=mobilize_america_settings3.6441.69

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 158 new files
Database: no new tables, 9 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-posts
mz_mobilize_america_instructions
widget_recent-comments
mz_mobilize_america_shortcodes
widget_theysaidso_widget
mz_mobilize_america_settings
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by MZ Mobilize America Interface
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,960 ▲21415.11 ▲0.741.77 ▼0.0840.24 ▼2.42
Dashboard /wp-admin2,366 ▲1756.55 ▲0.51138.32 ▲34.0741.40 ▲2.49
Posts /wp-admin/edit.php2,272 ▲1803.53 ▲1.3553.95 ▲10.7634.17 ▼1.43
Add New Post /wp-admin/post-new.php1,531 ▼1223.27 ▲5.01619.82 ▼6.3135.13 ▼30.39
Media Library /wp-admin/upload.php1,414 ▲324.26 ▲0.0782.78 ▼14.5538.92 ▼6.75
MZ Mobilize America /wp-admin/options-general.php?page=mobilize_america_settings1,2433.5149.4532.47

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin cannot be uninstalled
    • > Warning in wp-includes/class-wp-hook.php+310
    call_user_func_array() expects parameter 1 to be a valid callback, class 'MZ_Mobilize_America\\Core\Deactivator' not found
  • Zombie WordPress options were found after uninstall: 9 options
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • mz_mobilize_america_settings
    • mz_mobilize_america_shortcodes
    • mz_mobilize_america_instructions
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 0% 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
Almost there! Just fix the following items
  • 7× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/mz-mobilize-america-interface/src/Frontend/views/events_raw.php
    • > /wp-content/plugins/mz-mobilize-america-interface/src/Admin/views/html-mobilize-america-admin-display.php
    • > /wp-content/plugins/mz-mobilize-america-interface/src/Frontend/views/organizations_raw.php
    • > /wp-content/plugins/mz-mobilize-america-interface/src/Frontend/views/events_red.php
    • > /wp-content/plugins/mz-mobilize-america-interface/src/Frontend/views/event.php
    • > /wp-content/plugins/mz-mobilize-america-interface/src/Frontend/views/html-mobilize-america-public-display.php
    • > /wp-content/plugins/mz-mobilize-america-interface/src/Frontend/views/organizations_ajax.php
  • 275× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/vendor/composer/installers/src/Composer/Installers/PimcoreInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'MZ_Mobilize_America\\Dependencies\\Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/src/Dependencies/Composer/Installers/MediaWikiInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'MZ_Mobilize_America\\Dependencies\\Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/src/Dependencies/Composer/Installers/PiwikInstaller.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/vendor/composer/installers/src/Composer/Installers/DframeInstaller.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/vendor/composer/installers/src/Composer/Installers/EliasisInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/vendor/composer/installers/src/Composer/Installers/GravInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/vendor/composer/installers/src/Composer/Installers/CraftInstaller.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'MZ_Mobilize_America\\Dependencies\\Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/src/Dependencies/Composer/Installers/ZikulaInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/vendor/composer/installers/src/Composer/Installers/SilverStripeInstaller.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/mz-mobilize-america-interface/vendor/composer/installers/src/Composer/Installers/OsclassInstaller.php:5

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please fix the following browser errors
    • > GET request to /wp-admin/options-general.php?page=mobilize_america_settings
    • > Network (severe)
    wp-content/plugins/mz-mobilize-america-interface/src/Admin/css/mz-mobilize-america-admin.css?ver=1.0.3 - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/options-general.php?page=mobilize_america_settings
    • > Network (severe)
    wp-content/plugins/mz-mobilize-america-interface/src/Admin/js/mz-mobilize-america-admin.js?ver=1.0.3 - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
2 plugin tags: comments, spam

mz-mobilize-america-interface/mz-mobilize-america.php 77% from 13 tests

This is the main PHP file of "MZ Mobilize America Interface" version 1.0.3, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Git Repository: A Git repository was detected inside this plugin
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: The principal plugin file should be the same as the plugin slug ("mz-mobilize-america-interface.php" instead of "mz-mobilize-america.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin10,342 lines of code in 292 files:
LanguageFilesBlank linesComment linesLines of code
PHP2661,7633,3998,732
Markdown51170533
JSON400406
Bourne Shell35130266
CSS31126151
YAML4303119
XML37251
PO File1121250
JavaScript355834

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity2.83
▷ Minimum class complexity1.00
▷ Maximum class complexity62.00
Average method complexity1.95
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces18
Interfaces0
Traits0
Classes250
▷ Abstract classes83.20%
▷ Concrete classes24296.80%
▷ Final classes00.00%
Methods470
▷ Static methods6413.62%
▷ Public methods36277.02%
▷ Protected methods8017.02%
▷ Private methods285.96%
Functions21
▷ Named functions523.81%
▷ Anonymous functions1676.19%
Constants14
▷ Global constants750.00%
▷ Class constants750.00%
▷ Public constants7100.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
No PNG images were found in this plugin