Code clean up. Remove some duplicate keys; Remove some unused parameters; Fix some FQCN;

This commit is contained in:
Luis Henrique Mulinari
2017-10-11 21:19:07 +02:00
parent e426eff98c
commit 968bc6a3ce
9 changed files with 12 additions and 17 deletions

View File

@@ -149,7 +149,7 @@ class ComponentController extends Controller
$tags = preg_split('/ ?, ?/', $tags);
// For every tag, do we need to create it?
$componentTags = array_map(function ($taggable) use ($component) {
$componentTags = array_map(function ($taggable) {
return Tag::firstOrCreate(['name' => $taggable])->id;
}, $tags);
@@ -203,7 +203,7 @@ class ComponentController extends Controller
$tags = preg_split('/ ?, ?/', $tags);
// For every tag, do we need to create it?
$componentTags = array_map(function ($taggable) use ($component) {
$componentTags = array_map(function ($taggable) {
return Tag::firstOrCreate(['name' => $taggable])->id;
}, $tags);