mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-10-02 13:39:41 +02:00
Performance improvements: - Throttle cleanupExpiredTodos() to run every 30s instead of every chunk - Add early exit in detectTodoItems() for lines without todo markers - Remove redundant PROMISE_PATTERN check from LOOP_START_PATTERN Code quality: - Extract activateLoopIfNeeded() helper to eliminate duplicate loop start logic - Improve hash function using djb2 algorithm for better distribution - Add guards for empty/whitespace-only content in upsertTodo() - Simplify startLoop() to use existing enable() method Tests: - Add 5 new tests for edge cases and optimizations - Test empty content handling, early exit, ID uniqueness Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>