mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 22:10:45 +02:00
[feature/attach-dl] Moved include of compress class inside function
PHPBB3-11042
This commit is contained in:
@@ -1298,6 +1298,11 @@ function get_user_avatar($avatar, $avatar_type, $avatar_width, $avatar_height, $
|
|||||||
*/
|
*/
|
||||||
function phpbb_gen_download_links($param_key, $param_val, $phpbb_root_path, $phpEx)
|
function phpbb_gen_download_links($param_key, $param_val, $phpbb_root_path, $phpEx)
|
||||||
{
|
{
|
||||||
|
if (!class_exists('compress'))
|
||||||
|
{
|
||||||
|
require $phpbb_root_path . 'includes/functions_compress.' . $phpEx;
|
||||||
|
}
|
||||||
|
|
||||||
$methods = compress::methods();
|
$methods = compress::methods();
|
||||||
$links = array();
|
$links = array();
|
||||||
|
|
||||||
|
@@ -1318,7 +1318,6 @@ $template->assign_vars(array(
|
|||||||
'S_HAS_ATTACHMENTS' => !empty($attachments),
|
'S_HAS_ATTACHMENTS' => !empty($attachments),
|
||||||
));
|
));
|
||||||
|
|
||||||
require_once $phpbb_root_path . 'includes/functions_compress.' . $phpEx;
|
|
||||||
$methods = phpbb_gen_download_links('topic_id', $topic_id, $phpbb_root_path, $phpEx);
|
$methods = phpbb_gen_download_links('topic_id', $topic_id, $phpbb_root_path, $phpEx);
|
||||||
foreach ($methods as $method)
|
foreach ($methods as $method)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user