Skip to content

Deduplicate parseJSON row helper between extensions v1 and v2 - #167

Merged
admdly merged 2 commits into
mainfrom
chore/dedupe-parse-json
Jul 30, 2026
Merged

Deduplicate parseJSON row helper between extensions v1 and v2#167
admdly merged 2 commits into
mainfrom
chore/dedupe-parse-json

Conversation

@admdly

@admdly admdly commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

Summary

  • src/services/extensions/v1/database.ts and v2/extensions-database.ts each defined an identical fallback-safe JSON parser for reading TEXT columns (releases/license/source etc.). This predates the Drizzle migration in Migrate database operations to Drizzle ORM and clean up scripts #166, noted there as a minor pre-existing nit.
  • Moved it to src/lib/json.ts and re-exported from each service's interfaces.ts, matching the existing pattern for sortReleasesDescending.

Both database.ts files defined an identical fallback-safe JSON parser
for reading TEXT columns; moved it to src/lib/json.ts and re-exported
it from each service's interfaces.ts, matching how sortReleasesDescending
is already shared the same way.
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 30, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
api 1fd7193 Commit Preview URL

Branch Preview URL
Jul 30 2026, 05:04 AM

@admdly admdly self-assigned this Jul 30, 2026

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 5 files

Auto-approved: Refactor that deduplicates an identical helper function across two extensions services without changing behavior.

Re-trigger cubic

@admdly
admdly merged commit 49efd17 into main Jul 30, 2026
9 checks passed
@admdly
admdly deleted the chore/dedupe-parse-json branch July 30, 2026 05:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant