/**
* {@inheritdoc}
*/
public function minimumVersion() { return static::SQLITE_MINIMUM_VERSION;
} /**
* {@inheritdoc}
*/
public function getFormOptions(array
$database) { $form = parent::
getFormOptions($database);
// Remove the options that only apply to client/server style databases.
unset($form['username'
],
$form['password'
],
$form['advanced_options'
]['host'
],
$form['advanced_options'
]['port'
]);
// Make the text more accurate for SQLite.
$form['database'
]['#title'
] =
t('Database file'
);
$form['database'
]['#description'
] =
t('The absolute path to the file where @drupal data will be stored. This must be writable by the web server and should exist outside of the web root.',
['@drupal' =>
drupal_install_profile_distribution_name()]);
$default_database = \Drupal::
getContainer()->
getParameter('site.path'
) . '/files/.ht.sqlite';
$form['database'
]['#default_value'
] =
empty($database['database'
]) ?
$default_database :
$database['database'
];
return $form;
}