Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. InstallCommand.php

function InstallCommand::validateProfile

Validates a user provided install profile.

Parameters

string $install_profile: Install profile to validate.

Return value

bool TRUE if the profile is valid, FALSE if not.

1 call to InstallCommand::validateProfile()
InstallCommand::execute in core/lib/Drupal/Core/Command/InstallCommand.php
Executes the current command.

File

core/lib/Drupal/Core/Command/InstallCommand.php, line 321

Class

InstallCommand
Installs a Drupal site for local testing/development.

Namespace

Drupal\Core\Command

Code

protected function validateProfile($install_profile) : bool {
    // Allow people to install hidden and non-distribution profiles if they
    // supply the argument.
    return array_key_exists($install_profile, $this->getProfiles(TRUE, FALSE));
}
RSS feed
Powered by Drupal