diff --git a/web/api/botconfig.php b/web/api/botconfig.php index f097b38..4496972 100644 --- a/web/api/botconfig.php +++ b/web/api/botconfig.php @@ -12,7 +12,7 @@ $project = $stmt->fetch(); if (!$project) { http_response_code(404); echo json_encode(['error' => 'Project not found']); exit; } $base = realpath($project['path']); -$config_path = $base . '/config.json'; +$config_path = $base . '/data/config.json'; if (!$base || !is_dir($base)) { echo json_encode(['error' => 'Project path not accessible']); exit; diff --git a/web/api/botlogs.php b/web/api/botlogs.php index b85b2b1..146b5b5 100644 --- a/web/api/botlogs.php +++ b/web/api/botlogs.php @@ -12,7 +12,7 @@ if (!$project) { http_response_code(404); echo json_encode(['error' => 'Project $psStmt = $db->prepare('SELECT value FROM project_settings WHERE project_id = ? AND key = ?'); $psStmt->execute([$pid, 'bot_log_file']); $row = $psStmt->fetch(); -$rel = $row ? $row['value'] : 'logs/bashybot.log'; +$rel = $row ? $row['value'] : 'data/bashybot.log'; $base = realpath($project['path']); $logPath = realpath($base . '/' . ltrim($rel, '/'));