Fixed mass tag and tag renaming
This commit is contained in:
parent
098f11bd09
commit
8e465720bc
2 changed files with 1 additions and 12 deletions
|
@ -130,7 +130,7 @@ class TagController
|
|||
$params = [
|
||||
'source' => 'mass-tag',
|
||||
'query' => $suppliedQuery ?: ' ',
|
||||
'additionalInfo' => $suppliedTag ? TagModel::validateTag($suppliedTag) : '',
|
||||
'additionalInfo' => $suppliedTag ? $suppliedTag : '',
|
||||
];
|
||||
if ($suppliedOldPage != 0 and $suppliedOldQuery == $suppliedQuery)
|
||||
$params['page'] = $suppliedOldPage;
|
||||
|
|
|
@ -54,7 +54,6 @@ final class TagModel extends AbstractCrudModel
|
|||
throw new SimpleException('Target tag already exists');
|
||||
|
||||
$sourceTag->setName($targetName);
|
||||
TagModel::validateTag($sourceTag->getName());
|
||||
self::save($sourceTag);
|
||||
});
|
||||
}
|
||||
|
@ -174,14 +173,4 @@ final class TagModel extends AbstractCrudModel
|
|||
}
|
||||
return $tags;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public static function validateTags($tags)
|
||||
{
|
||||
foreach ($tags as $key => $tag)
|
||||
$tags[$key] = self::validateTag($tag);
|
||||
|
||||
return $tags;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue