|
@@ 3220-3227 (lines=8) @@
|
| 3217 |
|
} |
| 3218 |
|
|
| 3219 |
|
// We are already checking so many files...just few more doesn't make any difference! :P |
| 3220 |
|
if (!empty($modSettings['currentAttachmentUploadDir'])) |
| 3221 |
|
$path = $modSettings['attachmentUploadDir'][$modSettings['currentAttachmentUploadDir']]; |
| 3222 |
|
|
| 3223 |
|
else |
| 3224 |
|
{ |
| 3225 |
|
$path = $modSettings['attachmentUploadDir']; |
| 3226 |
|
$id_folder_thumb = 1; |
| 3227 |
|
} |
| 3228 |
|
secureDirectory($path, true); |
| 3229 |
|
secureDirectory($cachedir); |
| 3230 |
|
|
|
@@ 3651-3655 (lines=5) @@
|
| 3648 |
|
$file_hash = sha1(md5($filename . time()) . mt_rand()); |
| 3649 |
|
|
| 3650 |
|
// Are we using multiple directories? |
| 3651 |
|
if (!empty($modSettings['currentAttachmentUploadDir'])) |
| 3652 |
|
$path = $modSettings['attachmentUploadDir'][$dir]; |
| 3653 |
|
|
| 3654 |
|
else |
| 3655 |
|
$path = $modSettings['attachmentUploadDir']; |
| 3656 |
|
|
| 3657 |
|
return $path . '/' . $attachment_id . '_' . $file_hash .'.dat'; |
| 3658 |
|
} |