diff --git a/src/Controller/CsvToArrayTrait.php b/src/Controller/CsvToArrayTrait.php
index 88a3b80..b1bf024 100644
--- a/src/Controller/CsvToArrayTrait.php
+++ b/src/Controller/CsvToArrayTrait.php
@@ -17,7 +17,7 @@ trait CsvToArrayTrait {
    *   An array of ids.
    */
   protected function csvToArray($strings) {
-    return !empty($strings) ? explode(',', $strings) : array();
+    return !empty($strings) ? explode(',', $strings) : [];
   }
 
 }
diff --git a/src/Form/TagcloudsAdminPage.php b/src/Form/TagcloudsAdminPage.php
index 310f11c..d5aa760 100644
--- a/src/Form/TagcloudsAdminPage.php
+++ b/src/Form/TagcloudsAdminPage.php
@@ -53,39 +53,39 @@ class TagcloudsAdminPage extends ConfigFormBase {
    */
   public function buildForm(array $form, FormStateInterface $form_state) {
     $config = $this->config('tagclouds.settings');
-    $options = array(
+    $options = [
       'title,asc' => $this->t('by title, ascending'), 'title,desc' => $this->t('by title, descending'),
       'count,asc' => $this->t('by count, ascending'), 'count,desc' => $this->t('by count, descending'),
       'random,none' => $this->t('random')
-    );
+    ];
     $sort_order = $config->get('sort_order');
-    $form['sort_order'] = array(
+    $form['sort_order'] = [
       '#type' => 'radios',
       '#title' => $this->t('Tagclouds sort order'),
       '#options' => $options,
       '#default_value' => (!empty($sort_order)) ? $sort_order : 'title,asc',
       '#description' => $this->t('Determines the sort order of the tags on the freetagging page.'),
-    );
+    ];
 
-    $options_display = array('style' => $this->t('Display Tags with Style'), 'count' => $this->t('Display Tags with Count'));
+    $options_display = ['style' => $this->t('Display Tags with Style'), 'count' => $this->t('Display Tags with Count')];
     $display_type = $config->get('display_type');
-    $form['display_type'] = array(
+    $form['display_type'] = [
       '#type' => 'radios',
       '#title' => $this->t('Tagclouds Display Type'),
       '#options' => $options_display,
       '#default_value' => (!empty($display_type)) ? $display_type : 'style',
       '#description' => $this->t('Determines the style of the page.'),
-    );
+    ];
 
-    $form['display_node_link'] = array(
+    $form['display_node_link'] = [
      '#type' => 'checkbox',
      '#title' => $this->t('Link term to node when only one content is tagged'),
      '#default_value' => $config->get('display_node_link'),
      '#description' => $this->t('When there is only one content tagged with a certain term, link that term to this node instead of the term list page.'),
-    );
+    ];
 
     $page_amount = $config->get('page_amount');
-    $form['page_amount'] = array(
+    $form['page_amount'] = [
       '#type' => 'textfield',
       '#size' => 5,
       '#title' => $this->t('Amount of tags on the pages'),
@@ -93,10 +93,10 @@ class TagcloudsAdminPage extends ConfigFormBase {
       '#description' => $this->t("The amount of tags that will show up in a cloud on the
         pages. Enter '0' to display all tags. Amount of tags in blocks must be
         configured in the block settings of the various cloud blocks."),
-    );
+    ];
 
     $levels = $config->get('levels');
-    $form['levels'] = array(
+    $form['levels'] = [
       '#type' => 'textfield',
       '#size' => 5,
       '#title' => $this->t('Number of levels'),
@@ -104,16 +104,16 @@ class TagcloudsAdminPage extends ConfigFormBase {
       '#description' => $this->t('The number of levels between the least popular
         tags and the most popular ones. Different levels will be assigned a different
         class to be themed in tagclouds.css'),
-    );
+    ];
 
     $lang = $this->languageManager->getLanguages();
     if (count($lang) > 1) {
-      $form['language_separation'] = array(
+      $form['language_separation'] = [
         '#type' => 'checkbox',
         '#title' => $this->t('Separation of Tags per language'),
         '#default_value' => $config->get('language_separation'),
         '#description' => $this->t('If you have more than one language installed this setting would allow you to separate the tags for each language.'),
-      );
+      ];
     }
 
     return parent::buildForm($form, $form_state);
diff --git a/src/Plugin/Block/TagcloudsTermsBlock.php b/src/Plugin/Block/TagcloudsTermsBlock.php
index 96212f6..0bcbf91 100644
--- a/src/Plugin/Block/TagcloudsTermsBlock.php
+++ b/src/Plugin/Block/TagcloudsTermsBlock.php
@@ -28,12 +28,12 @@ class TagcloudsTermsBlock extends BlockBase {
    * {@inheritdoc}
    */
   public function defaultConfiguration() {
-    return array(
-      'cache' => array(
+    return [
+      'cache' => [
         'max_age' => 0,
-        'contexts' => array(),
-      ),
-    );
+        'contexts' => [],
+      ],
+    ];
   }
 
   /**
@@ -41,18 +41,18 @@ class TagcloudsTermsBlock extends BlockBase {
    */
   public function blockForm($form, FormStateInterface $form_state) {
     $terms_limit = isset($this->configuration['tags']) ? $this->configuration['tags'] : 0;
-    $form['tags'] = array(
+    $form['tags'] = [
       '#type' => 'textfield',
       '#title' => $this->t('Tags to show'),
       '#default_value' => $terms_limit,
       '#maxlength' => 3,
       '#description' => $this->t("The number of tags to show in this block. Enter '0' to display all tags."),
-    );
-    $form['vocabulary'] = array(
+    ];
+    $form['vocabulary'] = [
       '#type' => 'textfield',
       '#title' => $this->t('Vocabulary machine name'),
       '#default_value' => 'tags',
-    );
+    ];
 
     return $form;
   }
diff --git a/src/Plugin/Derivative/TagcloudsTermsBlock.php b/src/Plugin/Derivative/TagcloudsTermsBlock.php
index b484ba3..697798c 100644
--- a/src/Plugin/Derivative/TagcloudsTermsBlock.php
+++ b/src/Plugin/Derivative/TagcloudsTermsBlock.php
@@ -28,7 +28,7 @@ class TagcloudsTermsBlock extends DeriverBase implements DeriverInterface {
   public function getDerivativeDefinitions($base_plugin_definition) {
     foreach (Vocabulary::loadMultiple() as $voc) {
       $this->derivatives[$voc->id()] = $base_plugin_definition;
-      $this->derivatives[$voc->id()]['admin_label'] = $this->t('Tags in @voc', array('@voc' => $voc->label()));
+      $this->derivatives[$voc->id()]['admin_label'] = $this->t('Tags in @voc', ['@voc' => $voc->label()]);
     }
     return parent::getDerivativeDefinitions($base_plugin_definition);
   }
diff --git a/src/TagService.php b/src/TagService.php
index 9c66927..80e2853 100644
--- a/src/TagService.php
+++ b/src/TagService.php
@@ -91,7 +91,7 @@ class TagService implements TagServiceInterface {
     // Check if the cache exists.
     $cache_name = 'tagclouds_cache_' . $options;
     $cache = $this->cacheStore->get($cache_name);
-    $tags = array();
+    $tags = [];
     // Make sure cache has data.
     if (!empty($cache->data)) {
       $tags = $cache->data;
@@ -99,14 +99,14 @@ class TagService implements TagServiceInterface {
     else {
 
       if (count($vids) == 0) {
-        return array();
+        return [];
       }
       $config = $this->configFactory->get('tagclouds.settings');
 
       $query = db_select('taxonomy_term_data', 'td');
       $query->addExpression('COUNT(td.tid)', 'count');
-      $query->fields('tfd', array('name', 'description__value'));
-      $query->fields('td', array('tid', 'vid'));
+      $query->fields('tfd', ['name', 'description__value']);
+      $query->fields('td', ['tid', 'vid']);
 
       $query->join('taxonomy_index', 'tn', 'td.tid = tn.tid');
       $query->join('node_field_data', 'n', 'tn.nid = n.nid');
@@ -166,7 +166,7 @@ class TagService implements TagServiceInterface {
   private function buildWeightedTags($tags, $steps = 6) {
     // Find minimum and maximum log-count. By our MatheMagician Steven Wittens
     // aka UnConeD.
-    $tags_tmp = array();
+    $tags_tmp = [];
     $min = 1e9;
     $max = -1e9;
     foreach ($tags as $id => $tag) {
diff --git a/tagclouds.module b/tagclouds.module
index 12e1b03..79e4485 100755
--- a/tagclouds.module
+++ b/tagclouds.module
@@ -43,7 +43,7 @@ function tagclouds_theme() {
  * Adapted from i18n_taxonomy_term_name(). Should moved to i18n, issue http://drupal.org/node/1704658.
  */
 function tagclouds_i18n_taxonomy_term_description($term, $langcode = NULL) {
-  return i18n_taxonomy_vocabulary_mode($term->vid, I18N_MODE_LOCALIZE) ? i18n_string(array('taxonomy', 'term', $term->tid, 'description'), $term->description, array('langcode' => $langcode, 'sanitize' => FALSE)) : $term->description;
+  return i18n_taxonomy_vocabulary_mode($term->vid, I18N_MODE_LOCALIZE) ? i18n_string(['taxonomy', 'term', $term->tid, 'description'], $term->description, ['langcode' => $langcode, 'sanitize' => FALSE]) : $term->description;
 }
 
 /**
@@ -51,5 +51,5 @@ function tagclouds_i18n_taxonomy_term_description($term, $langcode = NULL) {
  * Adapted from i18n_taxonomy_vocabulary_name(). Should moved to i18n, issue http://drupal.org/node/1704658.
  */
 function tagclouds_i18n_taxonomy_vocabulary_description($vocabulary, $langcode = NULL) {
-  return i18n_object_langcode($vocabulary) ? $vocabulary->description : i18n_string(array('taxonomy', 'vocabulary', $vocabulary->vid, 'description'), $vocabulary->description, array('langcode' => $langcode));
+  return i18n_object_langcode($vocabulary) ? $vocabulary->description : i18n_string(['taxonomy', 'vocabulary', $vocabulary->vid, 'description'], $vocabulary->description, ['langcode' => $langcode]);
 }
