---
id: w7/m5/t006
title: Simplify — /simplify over the code this milestone changed
worker: worker7
status: done
estimate: 20m
depends_on: [w7/m5/t005]
---

## Objective

Run `/simplify` over the code this milestone changed (CRD field, operator route projection, the three adapters, dashboard section) for reuse / simplification / efficiency — behavior-preserving only.

## Context

- Scope: `lego/types/v1alpha1/keyvalue_types.go`, `lego/operator/internal/controller/keyvalue_controller.go`, `lego/backend/internal/keyvalue/{rest,graphql,mcp}.go`, the dashboard KV Networking section.
- Watch for: the allowlist middleware construction being shareable with the Postgres path rather than duplicated; the CIDR-list editor reusing the Postgres component.

## Steps

1. Run `/simplify` over the milestone's diff.
2. Apply behavior-preserving cleanups; re-run `cd lego/backend && go build ./... && go test ./...` and the operator build.

## Files

- Files touched in t001–t004.

## Acceptance criteria

- [ ] `/simplify` run; cleanups applied or explicitly declined with reason.
- [ ] Builds + tests still pass; no behavior change.

## Out of scope

- New behavior or coverage (t003/t007).
