Clean up dead Go code in handlers, pages, and stores
- Remove "chat" from surface disable guard (only admin needs it) - Remove "chat" from IsSurfaceEnabled always-on check - Remove unused fmt.Sprintf references in team stores - Update stale comments referencing personas and chat surfaces Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -48,11 +48,10 @@ func (e *Engine) SeedSurfaces() {
|
||||
}
|
||||
|
||||
// IsSurfaceEnabled checks if a surface is enabled in the registry.
|
||||
// Chat and Admin are always enabled (system-critical).
|
||||
// Admin is always enabled (system-critical).
|
||||
// Returns true if the surface is not found (fail-open for backward compat).
|
||||
func (e *Engine) IsSurfaceEnabled(surfaceID string) bool {
|
||||
// Chat and Admin cannot be disabled — they're system-critical
|
||||
if surfaceID == "chat" || surfaceID == "admin" {
|
||||
if surfaceID == "admin" {
|
||||
return true
|
||||
}
|
||||
if e.stores.Packages == nil {
|
||||
|
||||
Reference in New Issue
Block a user