半角スペースを含むタグは受け付けない

This commit is contained in:
shibafu
2020-05-22 00:27:32 +09:00
parent 54b6ff2282
commit 3a2d0e67aa
3 changed files with 15 additions and 0 deletions

View File

@@ -178,6 +178,9 @@ class CheckinCsvImporter
if (strpos($tag, "\n") !== false) {
throw new CsvImportException("{$line} 行 : {$column}に改行を含めることはできません。");
}
if (strpos($tag, ' ') !== false) {
throw new CsvImportException("{$line} 行 : {$column}にスペースを含めることはできません。");
}
$tags[] = Tag::firstOrCreate(['name' => $tag]);
if (count($tags) >= 32) {