Problem/Motivation

This module has several coding standards, dependency injection and security
violations that prevent it from passing Drupal.org's security advisory coverage
("green shield") review. These include raw HTML concatenation in hook_help,
direct service container access, missing strict types declarations, a confusing
create() return type, and rendering the node as a pre-rendered string instead of
a render array.

Steps to reproduce

  1. Run phpcs --standard=Drupal,DrupalPractice over the module.
  2. Observe the violations listed in the proposed resolution.

Proposed resolution

  • Escape/return plain text in hook_help() instead of concatenated HTML.
  • Move hook logic to the hook class with dependency injection (config factory, entity type manager).
  • Pass a render array (not a pre-rendered string) to the maintenance page template.
  • Add declare(strict_types=1) consistently.
  • Simplify create() to return static.
  • Remove duplicate hook implementations between the module file and the hook class.
  • Add a configure route, default config, and improved schema.

Remaining tasks

Maintainer review, merge, release.

User interface changes

None.

API changes

None. Internal implementation only.

Data model changes

None.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

alexismmd created an issue.

alexismmd’s picture

Hi @aaronsansal, thank you for maintaining this module!

I've opened a merge request with a set of coding standards, security and dependency injection fixes to make the module eligible for Drupal.org's security advisory coverage ("green shield").

It's a non-functional change: no user-facing behavior is affected, and rendering now properly respects node cache metadata.

Could you please review it when you get a chance? Happy to adjust anything based on your feedback.

Thanks a lot!