Skip to content

Commit

Permalink
Removed previous database and refer to new submission database
Browse files Browse the repository at this point in the history
  • Loading branch information
cultpodcasts committed Feb 17, 2024
1 parent e81d97c commit 3819df4
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 14 deletions.
1 change: 0 additions & 1 deletion create-sql-dump.cmd

This file was deleted.

11 changes: 0 additions & 11 deletions migrations/0000_full-text-search.sql

This file was deleted.

5 changes: 5 additions & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
export interface Env {
Content: R2Bucket;
Analytics: AnalyticsEngineDataset;
DB: D1Database;
apikey: string;
apihost: string;
}
Expand All @@ -10,6 +11,7 @@ export default {
const { pathname, searchParams } = new URL(request.url);
const homeRoute = "/homepage";
const searchRoute = "/api";
const submitRoute = "/submit";
const corsHeaders = {
"Access-Control-Allow-Origin": "*", //"https://cultpodcasts.com",
"Access-Control-Allow-Methods": "GET,HEAD,POST,OPTIONS",
Expand Down Expand Up @@ -117,6 +119,9 @@ export default {
});
}

if (pathname.startsWith(submitRoute)) {
}

return new Response(
`Call ${homeRoute} to get the last 7-days of new releases
${pathname}`,
Expand Down
4 changes: 2 additions & 2 deletions wrangler.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ bucket_name = "content"

[[d1_databases]]
binding = "DB"
database_name = "cultpodcasts"
database_id = "d60db6d1-994d-448d-9be1-5067d1be72d8"
database_name = "submissions"
database_id = "6d00eb71-b420-47f7-9e74-96d53bcb943a"

[[analytics_engine_datasets]]
binding = "Analytics"

0 comments on commit 3819df4

Please sign in to comment.