Fix session_start guards, add missing API routes, rewrite README
- Added session_status() === PHP_SESSION_NONE guard to six API files (custom_fields, revoke_api_key, manage_templates, generate_api_key, get_template, manage_recurring) that called bare session_start() after RateLimitMiddleware had already started the session - Registered /api/notifications.php and /api/user_avatar.php in index.php router (were missing, served only by direct file access) - Complete README rewrite: remove all Discord references (Matrix/hookshot is the only external notification method), add hwmonDaemon API docs, document all TDS v1.2 features (kanban, charts, SLA, command palette, notification bell, watcher avatars, @mention, etc.), fix keyboard shortcuts table, add Matrix/LDAP env vars to setup section Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -191,6 +191,14 @@ switch (true) {
|
||||
require_once 'api/health.php';
|
||||
break;
|
||||
|
||||
case $requestPath == '/api/notifications.php':
|
||||
require_once 'api/notifications.php';
|
||||
break;
|
||||
|
||||
case $requestPath == '/api/user_avatar.php':
|
||||
require_once 'api/user_avatar.php';
|
||||
break;
|
||||
|
||||
// Admin Routes - require admin privileges
|
||||
case $requestPath == '/admin/recurring-tickets':
|
||||
requireAdmin($currentUser);
|
||||
|
||||
Reference in New Issue
Block a user