Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
b3b00 committed Dec 19, 2023
1 parent c7312aa commit 40e0f1a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions public/_worker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,8 @@ router.delete<D1Request, CF>('/d1/:tenant', withParams, withD1(), async (request
router.get('/d1/:tenant', withParams, withD1(), async (request:D1Request, env:Env) => {
const tenant:string = request.params.tenant
try {
console.log('getting data for '+tenant+' / '+tenant.toUpperCase());
console.log(env);
var d1Fromcontext = env[tenant.toUpperCase()];
if (!d1Fromcontext) {
return renderBadRequestJson(env,request,errorResult([`no bound D1 for ${tenant}`],null));
Expand Down

0 comments on commit 40e0f1a

Please sign in to comment.