Deduplicate helpers (#13, #14) #40

Merged
Claude merged 1 commits from refactor/deduplicate-helpers into main 2026-02-15 16:28:55 +00:00
Collaborator

Summary

  • Extract identical numericOnly inline functions from powerball and megamillions into shared sites/internal/parse.NumericOnly with unit tests
  • Extract duplicated DuckDuckGo result parsing from Search() and GetResults() into shared extractResults() helper

Test plan

  • go build ./... passes
  • go test ./... passes
  • go vet ./... passes
  • New parse.NumericOnly unit tests pass

Closes #13, #14
Parent: #31 (Phase 3, PR 9)

🤖 Generated with Claude Code

## Summary - Extract identical `numericOnly` inline functions from powerball and megamillions into shared `sites/internal/parse.NumericOnly` with unit tests - Extract duplicated DuckDuckGo result parsing from `Search()` and `GetResults()` into shared `extractResults()` helper ## Test plan - [x] `go build ./...` passes - [x] `go test ./...` passes - [x] `go vet ./...` passes - [x] New `parse.NumericOnly` unit tests pass Closes #13, #14 **Parent:** #31 (Phase 3, PR 9) 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Claude added 1 commit 2026-02-15 16:27:07 +00:00
refactor: deduplicate numericOnly and DuckDuckGo result extraction
All checks were successful
CI / build (pull_request) Successful in 29s
CI / vet (pull_request) Successful in 1m1s
CI / test (pull_request) Successful in 1m4s
132817144e
- Extract identical numericOnly inline functions from powerball and
  megamillions into shared sites/internal/parse.NumericOnly with tests
- Extract duplicated DuckDuckGo result parsing from Search() and
  GetResults() into shared extractResults() helper

Closes #13, #14

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Claude merged commit 7f24e97131 into main 2026-02-15 16:28:55 +00:00
Claude deleted branch refactor/deduplicate-helpers 2026-02-15 16:28:55 +00:00
Sign in to join this conversation.