Pathologic was missing because of a .git folder inside.
[yaffs-website] / web / modules / contrib / imagemagick / imagemagick.install
1 <?php
2
3 /**
4  * @file
5  * ImageMagick installation scripts.
6  */
7
8 /**
9  * Implements hook_requirements().
10  */
11 function imagemagick_requirements($phase) {
12
13   $requirements = [];
14
15   if ($phase === 'install' && stripos(ini_get('disable_functions'), 'proc_open') !== FALSE) {
16     $reported_info = [];
17     // proc_open() is disabled.
18     $severity = REQUIREMENT_ERROR;
19     $reported_info[] = t("The <a href=':proc_open_url'>proc_open()</a> PHP function is disabled. It must be enabled for the toolkit to be installed. Edit the <a href=':disable_functions_url'>disable_functions</a> entry in your php.ini file, or consult your hosting provider.", [
20       ':proc_open_url' => 'http://php.net/manual/en/function.proc-open.php',
21       ':disable_functions_url' => 'http://php.net/manual/en/ini.core.php#ini.disable-functions',
22     ]);
23
24     $requirements = [
25       'imagemagick' => [
26         'title' => t('ImageMagick'),
27         'description' => [
28           '#markup' => implode('<br />', $reported_info),
29         ],
30         'severity' => $severity,
31       ],
32     ];
33   }
34
35   return $requirements;
36 }
37
38 /**
39  * @addtogroup updates-8.x-1.0-alpha
40  * @{
41  */
42
43 /**
44  * Adds the 'locale' config setting.
45  */
46 function imagemagick_update_8001() {
47   $config_factory = \Drupal::configFactory();
48   $setting = $config_factory->getEditable('imagemagick.settings')
49     ->set('locale', 'en_US.UTF-8')
50     ->save(TRUE);
51 }
52
53 /**
54  * Adds the 'log_warnings' config setting.
55  */
56 function imagemagick_update_8002() {
57   $config_factory = \Drupal::configFactory();
58   $setting = $config_factory->getEditable('imagemagick.settings')
59     ->set('log_warnings', TRUE)
60     ->save(TRUE);
61 }
62
63 /**
64  * @} End of "addtogroup updates-8.x-1.0-alpha".
65  */