mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-14 04:20:49 +08:00
claim bulk
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
defined('VERSION_NUMBER') || define('VERSION_NUMBER', '1.8.0');
|
||||
defined('RELEASE_DATE') || define('RELEASE_DATE', '2023-03-06');
|
||||
defined('RELEASE_DATE') || define('RELEASE_DATE', '2023-03-13');
|
||||
defined('IN_TRACKER') || define('IN_TRACKER', false);
|
||||
defined('PROJECTNAME') || define("PROJECTNAME","NexusPHP");
|
||||
defined('NEXUSPHPURL') || define("NEXUSPHPURL","https://nexusphp.org");
|
||||
|
||||
@@ -576,9 +576,10 @@ function int_check($value,$stdhead = false, $stdfood = true, $die = true, $log =
|
||||
{
|
||||
if (!is_valid_id($value)) {
|
||||
$msg = "Invalid ID Attempt: Username: ".$CURUSER["username"]." - UserID: ".$CURUSER["id"]." - UserIP : ".getip();
|
||||
if ($log)
|
||||
write_log($msg,'mod');
|
||||
|
||||
if ($log) {
|
||||
write_log($msg,'mod');
|
||||
}
|
||||
do_log($msg, 'error');
|
||||
if ($stdhead)
|
||||
stderr($lang_functions['std_error'],$lang_functions['std_invalid_id']);
|
||||
else
|
||||
|
||||
@@ -232,11 +232,11 @@ function do_log($log, $level = 'info', $echo = false)
|
||||
}
|
||||
}
|
||||
|
||||
function getLogFile()
|
||||
function getLogFile($append = '')
|
||||
{
|
||||
static $logFile;
|
||||
if (!is_null($logFile)) {
|
||||
return $logFile;
|
||||
static $logFiles = [];
|
||||
if (isset($logFiles[$append])) {
|
||||
return $logFiles[$append];
|
||||
}
|
||||
$config = nexus_config('nexus');
|
||||
$path = getenv('NEXUS_LOG_DIR', true);
|
||||
@@ -257,8 +257,12 @@ function getLogFile()
|
||||
$prefix = $logFile;
|
||||
$suffix = '';
|
||||
}
|
||||
$logFile = sprintf('%s-%s%s', $prefix, date('Y-m-d'), $suffix);
|
||||
return $logFile;
|
||||
$name = $prefix;
|
||||
if ($append) {
|
||||
$name .= "-$append";
|
||||
}
|
||||
$logFile = sprintf('%s-%s%s', $name, date('Y-m-d'), $suffix);
|
||||
return $logFiles[$append] = $logFile;
|
||||
|
||||
}
|
||||
|
||||
@@ -1172,3 +1176,8 @@ function executeCommand($command, $format = 'string', $artisan = false, $excepti
|
||||
return $format == 'string' ? $outputString : $output;
|
||||
}
|
||||
|
||||
function has_role_work_seeding($uid)
|
||||
{
|
||||
return apply_filter('user_has_role_work_seeding', false, $uid);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user