62% seo-for-local

Code Review | Local SEO For Divi & Gutenberg Blocks

WordPress plugin Local SEO For Divi & Gutenberg Blocks scored62%from 54 tests.

About plugin

  • Plugin page: seo-for-local
  • Plugin version: 9.2.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.3
  • WordPress version: 6.3.1
  • First release: Nov 11, 2021
  • Latest release: Aug 28, 2023
  • Number of updates: 12
  • Update frequency: every 54.6 days
  • Top authors: wpt00ls (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /570 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲5.75MB] [CPU: ▲43.83ms] 75% from 4 tests

This is a short check of server-side resources used by Local SEO For Divi & Gutenberg Blocks
It is recommended to improve the following
  • Extra RAM: Extra memory usage must be kept under 5MB (currently 5.75MB on /wp-admin/admin.php?page=freemius)
PageMemory (MB)CPU Time (ms)
Home /9.20 ▲5.7382.88 ▲42.96
Dashboard /wp-admin9.08 ▲5.7792.09 ▲45.70
Posts /wp-admin/edit.php9.13 ▲5.77107.83 ▲63.07
Add New Post /wp-admin/post-new.php11.83 ▲5.94124.07 ▲23.58
Media Library /wp-admin/upload.php8.98 ▲5.7495.72 ▲63.10
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius9.2477.60

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 768 new files
Database: no new tables, 9 new options
New WordPress options
can_compress_scripts
widget_recent-comments
db_upgraded
fs_active_plugins
widget_recent-posts
theysaidso_admin_options
fs_debug_mode
fs_accounts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Local SEO For Divi & Gutenberg Blocks
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,111 ▲35020.04 ▲5.6832.21 ▲30.6728.25 ▼12.91
Dashboard /wp-admin2,408 ▲2279.05 ▲3.36182.04 ▲84.9341.23 ▼0.01
Posts /wp-admin/edit.php2,343 ▲2436.22 ▲4.1593.60 ▲57.7538.21 ▲1.37
Add New Post /wp-admin/post-new.php1,745 ▲20925.25 ▲1.97773.17 ▲104.1740.92 ▼18.29
Media Library /wp-admin/upload.php1,473 ▲736.72 ▲2.58121.24 ▲22.4448.95 ▲4.84
Locations & SEO /wp-admin/crb_carbon_fields_container_locations_seo.php260.420.0614.31
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius1,3186.0177.9526.51

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/seo-for-local/freemius/includes/class-freemius.php+8486
    Undefined property: stdClass::$plugins
  • This plugin did not uninstall successfully, leaving 9 options in the database
    • fs_active_plugins
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • fs_debug_mode
    • widget_theysaidso_widget
    • fs_accounts
    • widget_recent-posts
    • widget_recent-comments

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

SRP 0% 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
The following issues need your attention
  • 5× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/seo-for-local/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php
    • > /wp-content/plugins/seo-for-local/resources/views/partials/location-map-info-window.php
    • > /wp-content/plugins/seo-for-local/resources/views/location-address.php
    • > /wp-content/plugins/seo-for-local/resources/views/partials/admin-css.php
    • > /wp-content/plugins/seo-for-local/resources/views/location-opening-hours.php
  • 145× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Field\\Field' not found in wp-content/plugins/seo-for-local/vendor/htmlburger/carbon-fields/core/Field/Map_Field.php:12
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/seo-for-local/vendor/htmlburger/carbon-fields/templates/Container/user_meta.php:1
    • > PHP Warning
      Invalid argument supplied for foreach() in wp-content/plugins/seo-for-local/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php on line 35
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Condition\\Condition' not found in wp-content/plugins/seo-for-local/vendor/htmlburger/carbon-fields/core/Container/Condition/Current_User_ID_Condition.php:8
    • > PHP Notice
      Undefined variable: errors in wp-content/plugins/seo-for-local/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php on line 35
    • > PHP Fatal error
      Uncaught Error: Class 'DiviExtension' not found in wp-content/plugins/seo-for-local/includes/modules/MultiLocationsExtension.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'ET_Builder_Module' not found in wp-content/plugins/seo-for-local/includes/modules/LocationAddressModule/LocationAddressModule.php:6
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Container\\ContainerExceptionInterface' not found in wp-content/plugins/seo-for-local/vendor/psr/container/src/NotFoundExceptionInterface.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Container' not found in wp-content/plugins/seo-for-local/vendor/htmlburger/carbon-fields/core/Container/Post_Meta_Container.php:14
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Container\otFoundExceptionInterface' not found in wp-content/plugins/seo-for-local/vendor/pimple/pimple/src/Pimple/Exception/UnknownIdentifierException.php:36

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
These are user-side errors you should fix
    • > GET request to /wp-admin/crb_carbon_fields_container_locations_seo.php
    • > Network (severe)
    wp-admin/crb_carbon_fields_container_locations_seo.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/admin.php?page=freemius
    • > Console-api (warning) in wp-content/plugins/seo-for-local/vendor/htmlburger/carbon-fields/build/classic/vendor.min.js?ver=3.6.0+48:54975
    wp.compose.withState is deprecated since version 5.8. Please use wp.element.useState instead.

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that require attention:
  • Tags: There are too many tags (11 tag instead of maximum 10)
You can look at the official readme.txt

seo-for-local/seo-for-local.php 92% from 13 tests

The main PHP script in "Local SEO For Divi & Gutenberg Blocks" version 9.2.2 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Domain Path: The domain path is invalid: folder "/languages" does not exist

Code Analysis 97% from 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
No dangerous file extensions were detected71,846 lines of code in 657 files:
LanguageFilesBlank linesComment linesLines of code
PHP33911,34525,59847,247
JavaScript1867,13810,99116,416
PO File288981,1112,411
CSS312631,1572,346
Sass4936531,868
JSON8301,004
SVG920333
reStructuredText19413597
Markdown429076
YAML15035
XML11013

PHP code 50% from 2 tests

An overview of cyclomatic complexity and code structure
Please fix the following
  • Please reduce cyclomatic complexity of classes to less than 1000 (currently 3,073)
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity24.82
▷ Minimum class complexity1.00
▷ Maximum class complexity3,073.00
Average method complexity3.36
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces47
Interfaces9
Traits0
Classes229
▷ Abstract classes135.68%
▷ Concrete classes21694.32%
▷ Final classes41.85%
Methods2,486
▷ Static methods30412.23%
▷ Public methods1,92777.51%
▷ Protected methods1827.32%
▷ Private methods37715.16%
Functions289
▷ Named functions12643.60%
▷ Anonymous functions16356.40%
Constants176
▷ Global constants10459.09%
▷ Class constants7240.91%
▷ Public constants72100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
11 PNG files occupy 0.06MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/4.png5.57KB4.23KB▼ 24.08%
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
images/3.png3.86KB3.06KB▼ 20.80%
images/1.png2.93KB2.20KB▼ 25.07%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%