Skip to content

Commit

Permalink
Merge pull request #30 from llaski/bugfix/laravel-6-support
Browse files Browse the repository at this point in the history
Laravel 6 Support
  • Loading branch information
Rias committed Sep 13, 2019
2 parents 038bdab + c4e1d62 commit aadef9d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/DataLayer.php
Expand Up @@ -2,6 +2,8 @@

namespace Spatie\GoogleTagManager;

use Illuminate\Support\Arr;

class DataLayer
{
/**
Expand All @@ -25,13 +27,13 @@ public function set($key, $value = null)
{
if (is_array($key)) {
foreach ($key as $innerKey => $innerValue) {
array_set($this->data, $innerKey, $innerValue);
Arr::set($this->data, $innerKey, $innerValue);
}

return;
}

array_set($this->data, $key, $value);
Arr::set($this->data, $key, $value);
}

/**
Expand Down

0 comments on commit aadef9d

Please sign in to comment.