Checked PSR-1 / PHP 8.1 Undefiend Varialbe, Type error

This commit is contained in:
kjh
2022-05-31 05:53:49 +00:00
parent 993e689800
commit 1fb9b5051c
13 changed files with 1011 additions and 967 deletions

View File

@ -1,16 +1,21 @@
<?php
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
if (!defined('_GNUBOARD_')) {
exit; // 개별 페이지 접근 불가
}
function social_log_file_delete($second=0){
$files = glob(G5_DATA_PATH.'/tmp/social_*');
function social_log_file_delete($second = 0)
{
$files = glob(G5_DATA_PATH . '/tmp/social_*');
if (is_array($files)) {
$before_time = $second ? G5_SERVER_TIME - $second : 0;
foreach ($files as $social_log_file) {
$modification_time = filemtime($log_file); // 파일접근시간
$modification_time = filemtime($social_log_file); // 파일접근시간
if ($before_time && $modification_time > $before_time) continue;
if ($before_time && $modification_time > $before_time) {
continue;
}
unlink($social_log_file);
}
}
}
}