diff --git a/gitinfo.install b/gitinfo.install
index 053b4ad..d6d0fad 100644
--- a/gitinfo.install
+++ b/gitinfo.install
@@ -5,9 +5,9 @@
  * Status report info for the GIT Info Report module.
  */
 
+use Drupal\Component\Render\FormattableMarkup;
 use Drupal\Core\Link;
 use Drupal\Core\Url;
-use Drupal\Component\Render\FormattableMarkup;
 
 /**
  * Implements hook_requirements().
@@ -59,7 +59,7 @@ function gitinfo_requirements($phase) {
       $error = TRUE;
     }
     // Detection method for a non-Unix OS. 'which' command is typical for Unix.
-    elseif (!(strpos(`which find`, '/find') !== FALSE)) {
+    elseif (!(strpos(shell_exec('which find'), '/find') !== FALSE)) {
       $value = t("The terminal command 'find' is not available. The server's OS is probably non-Unix. Uninstall the @gitinfo module.", ['@gitinfo' => $gitinfo_module]);
       $severity = REQUIREMENT_ERROR;
       $error = TRUE;
diff --git a/src/Form/GitinfoSettingsForm.php b/src/Form/GitinfoSettingsForm.php
index 8b05112..c3ff7db 100644
--- a/src/Form/GitinfoSettingsForm.php
+++ b/src/Form/GitinfoSettingsForm.php
@@ -2,10 +2,12 @@
 
 namespace Drupal\gitinfo\Form;
 
+use Drupal\Core\Datetime\DateFormatterInterface;
 use Drupal\Core\Form\ConfigFormBase;
 use Drupal\Core\Form\FormStateInterface;
 use Drupal\Core\Link;
 use Drupal\Core\Url;
+use Symfony\Component\DependencyInjection\ContainerInterface;
 
 /**
  * Class GitinfoSettingsForm.
@@ -28,6 +30,31 @@ class GitinfoSettingsForm extends ConfigFormBase {
     return 'gitinfo_settings';
   }
 
+  /**
+   * The date formatter service.
+   *
+   * @var \Drupal\Core\Datetime\DateFormatterInterface
+   */
+  protected $dateFormatter;
+
+  /**
+   * Use core services object.
+   */
+  public function __construct(
+    DateFormatterInterface $date_formatter
+  ) {
+    $this->dateFormatter = $date_formatter;
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public static function create(ContainerInterface $container) {
+    return new static(
+      $container->get('date.formatter')
+    );
+  }
+
   /**
    * {@inheritdoc}
    */
@@ -40,8 +67,8 @@ class GitinfoSettingsForm extends ConfigFormBase {
     ];
     $form['connect'] = [
       '#type' => 'checkbox',
-      '#title' => $this->t('Connect with remote repos'),
-      '#description' => $this->t("<strong>Slows down report generation</strong> but it tells if your working directory is behind compared with the remote repo. In other words, if a 'git pull' is needed. Furthermore, it shows if your Git version is up to date."),
+      '#title' => $this->t('Connect with remote repos and check if your Git version is up to date'),
+      '#description' => $this->t("<strong>Slows down report generation</strong> but it tells if your working directory is behind compared with the remote repo. In other words, if a 'git pull' is needed."),
       '#default_value' => $config->get('connect'),
     ];
     $explain_title = NULL;
@@ -85,10 +112,9 @@ class GitinfoSettingsForm extends ConfigFormBase {
     $form['fuzzy_timestamp_granularity'] = [
       '#type' => 'number',
       '#title' => $this->t('Fuzzy timestamp granularity (<em>time ago</em> date format)'),
-      '#description' => $this->t("Examples of output with the current granularity: <em><strong>@sample_old ago</strong></em> (years back), <em><strong>@sample_recent ago</strong></em> (recent)<br />The minimum of '1' results for example in <em>'2 weeks ago'</em>. A value of '5' (or higher) in <em>'2 weeks 4 days 18 hours 10 min 15 sec ago'</em>.<br />A low granularity is understood at a glance though less accurate. The exact date and time is shown on mouse-over anyway (see below). Default: <em>1</em><br />Granularity is not the same as the number of units. Following units in the hierarchy will not get skipped. For example <em>'5 months 19 hours'</em> will always be shown as <em>'5 months'</em>, independent from the granularity set. After a week it will then turn into <em>'5 months 1 week'</em>.", [
-        '@sample_old' => \Drupal::service("date.formatter")
-          ->formatInterval(81950198, $config->get('fuzzy_timestamp_granularity')), '@sample_recent' => \Drupal::service("date.formatter")
-          ->formatInterval(76477, $config->get('fuzzy_timestamp_granularity')),
+      '#description' => $this->t("Examples of output with the current defined granularity: <em><strong>@sample_old ago</strong></em> (years back), <em><strong>@sample_recent ago</strong></em> (recent)<br />The minimum of '1' results for example in <em>'2 weeks ago'</em>. A value of '5' (or higher) in <em>'2 weeks 4 days 18 hours 10 min 15 sec ago'</em>.<br />A low granularity is understood at a glance though less accurate. The exact date and time is shown on mouse-over anyway (see below). Default: <em>1</em><br />Granularity is not the same as the number of units. Following units in the hierarchy will not get skipped. For example <em>'5 months 19 hours'</em> will always be shown as <em>'5 months'</em>, independent from the granularity set. After a week it will then turn into <em>'5 months 1 week'</em>.", [
+        '@sample_old' => $this->dateFormatter->formatInterval(81950198, $config->get('fuzzy_timestamp_granularity')),
+        '@sample_recent' => $this->dateFormatter->formatInterval(76477, $config->get('fuzzy_timestamp_granularity')),
       ]),
       '#default_value' => $config->get('fuzzy_timestamp_granularity'),
       '#min' => 1,
