1
0
mirror of https://github.com/e107inc/e107.git synced 2025-04-21 13:11:52 +02:00

Issue #591 - Optimize downloads import

This commit is contained in:
Cameron 2014-05-31 18:34:38 -07:00
parent a535a6df60
commit 0d063b82a8

View File

@ -1526,8 +1526,14 @@ function update_706_to_800($type='')
while($row = $sql->fetch())
{
$suffix = strrchr($row['download_url'], ".");
$allowed_types[] = ltrim($suffix,".");
$ext = strrchr($row['download_url'], ".");
$suffix = ltrim($ext,".");
if(!isset($allowed_types[$suffix]))
{
$allowed_types[$suffix] = $suffix;
}
}
$allowed_types = array_unique($allowed_types);