Skip to content

Commit

Permalink
fix: Fixed a bug which caused a major outage of the APIs
Browse files Browse the repository at this point in the history
  • Loading branch information
FleetAdmiralJakob committed Jan 21, 2024
1 parent 4c6ce7c commit da04dac
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions apps/web/next.config.mjs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
// Importing env files here to validate on build
import './src/env.mjs'
import '@weatherio/api/env'
import withBundleAnalyzer from '@next/bundle-analyzer'
import pkg from './next-i18next.config.js'
import withPWAInit from '@ducanh2912/next-pwa'
Expand Down
3 changes: 2 additions & 1 deletion packages/api/env.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export const env = createEnv({
UPSTASH_RATELIMITER_EXCLUDED_IPS: z.string().min(1),
RESEND_API_KEY: z.string().min(1),
QWEATHER_API_KEY: z.string().min(1),
API_NINJA_API_KEY: z.string().min(1)
API_NINJA_API_KEY: z.string().min(1),
},
client: {},
runtimeEnv: {
Expand All @@ -22,6 +22,7 @@ export const env = createEnv({
UPSTASH_REDIS_REST_TOKEN: process.env.UPSTASH_REDIS_REST_TOKEN,
UPSTASH_RATELIMITER_TOKENS_PER_TIME: process.env.UPSTASH_RATELIMITER_TOKENS_PER_TIME,
UPSTASH_RATELIMITER_TIME_INTERVAL: process.env.UPSTASH_RATELIMITER_TIME_INTERVAL,
UPSTASH_RATELIMITER_EXCLUDED_IPS: process.env.UPSTASH_RATELIMITER_EXCLUDED_IPS,
RESEND_API_KEY: process.env.RESEND_API_KEY,
QWEATHER_API_KEY: process.env.QWEATHER_API_KEY,
API_NINJA_API_KEY: process.env.API_NINJA_API_KEY
Expand Down
3 changes: 2 additions & 1 deletion packages/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
"private": true,
"type": "module",
"exports": {
".": "./src/index.ts"
".": "./src/index.ts",
"./env": "./env.mjs"
},
"license": "MIT",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion packages/api/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
"compilerOptions": {
"tsBuildInfoFile": "node_modules/.cache/tsbuildinfo.json"
},
"include": ["src", "../../reset.d.ts", "*.mjs"],
"include": ["src", "../../reset.d.ts", "**/*.mjs", "."],
"exclude": ["node_modules"]
}

1 comment on commit da04dac

@vercel
Copy link

@vercel vercel bot commented on da04dac Jan 21, 2024

Choose a reason for hiding this comment

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

Please sign in to comment.