Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
RouatbiH committed Sep 1, 2023
1 parent b295633 commit 965df8b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions includes/adm/start.php
Original file line number Diff line number Diff line change
Expand Up @@ -197,12 +197,12 @@
}

//no htaccess
if (! file_exists(PATH . $config['foldername'] . '/.htaccess'))
if (is_dir(PATH . $config['foldername']) && ! file_exists(PATH . $config['foldername'] . '/.htaccess'))
{
$ADM_NOTIFICATIONS['htaccess_u'] = ['id' => 'htaccess_u', 'msg_type'=> 'error', 'title'=> $lang['WARN'], 'msg'=> sprintf($lang['NO_HTACCESS_DIR_UP'], $config['foldername'])];
}

if (! file_exists(PATH . $config['foldername'] . '/thumbs/.htaccess'))
if (is_dir(PATH . $config['foldername']) && ! file_exists(PATH . $config['foldername'] . '/thumbs/.htaccess'))
{
$ADM_NOTIFICATIONS['htaccess_t'] = ['id' => 'htaccess_t', 'msg_type'=> 'error', 'title'=> $lang['WARN'], 'msg'=> sprintf($lang['NO_HTACCESS_DIR_UP_THUMB'], $config['foldername'] . '/thumbs')];
}
Expand All @@ -215,7 +215,7 @@
}

//if there is no thumbs folder
if (! file_exists(PATH . $config['foldername'] . '/thumbs') && (int) $config['thumbs_imgs'] != 0)
if (is_dir(PATH . $config['foldername']) && ! file_exists(PATH . $config['foldername'] . '/thumbs') && (int) $config['thumbs_imgs'] != 0)
{
$ADM_NOTIFICATIONS['no_thumbs'] = ['id' => 'no_thumbs', 'msg_type'=> 'info', 'title'=> $lang['NOTE'], 'msg'=> sprintf($lang['NO_THUMB_FOLDER'], PATH . $config['foldername'] . '/thumbs')];
}
Expand Down

0 comments on commit 965df8b

Please sign in to comment.