Change usage of basename where possible (#1480)

Change usage of basename where possible (#1480)
This commit is contained in:
Timothy Cyrus
2018-10-04 06:43:36 -04:00
committed by Matias Griese
parent 5247a76ec1
commit 85bb59e2b6
2 changed files with 8 additions and 8 deletions

View File

@@ -368,7 +368,7 @@ class AdminBaseController
// Generate random name if required
if ($settings->random_name) { // TODO: document
$extension = pathinfo($upload->file->name)['extension'];
$extension = pathinfo($upload->file->name, PATHINFO_EXTENSION);
$upload->file->name = Utils::generateRandomString(15) . '.' . $extension;
}