Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
DariusLukasukas committed Oct 28, 2023
1 parent 457e425 commit a7d8031
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion actions/getAirPollutionData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export const getAirPollutionData = async ({
lon: string
}) => {
const data = await fetch(
`${process.env.VERCEL_URL}/api/weather/air_pollution?lat=${lat}&lon=${lon}&appid=${process.env.NEXT_PUBLIC_OPEN_WEATHER_API_KEY}`
`https://${process.env.VERCEL_URL}/api/weather/air_pollution?lat=${lat}&lon=${lon}&appid=${process.env.NEXT_PUBLIC_OPEN_WEATHER_API_KEY}`
)
if (!data.ok) {
throw new Error("Failed to fetch data")
Expand Down
2 changes: 1 addition & 1 deletion actions/getHourlyData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export const getHourlyData = async ({
lon: string
}) => {
const data = await fetch(
`${process.env.VERCEL_URL}/api/weather/hourly?lat=${lat}&lon=${lon}&appid=${process.env.NEXT_PUBLIC_OPEN_WEATHER_API_KEY}`
`https://${process.env.VERCEL_URL}/api/weather/hourly?lat=${lat}&lon=${lon}&appid=${process.env.NEXT_PUBLIC_OPEN_WEATHER_API_KEY}`
)
if (!data.ok) {
throw new Error("Failed to fetch data")
Expand Down
2 changes: 1 addition & 1 deletion actions/getTenDayForecast.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export const getTenDayForecast = async ({
lon: string
}) => {
const data = await fetch(
`${process.env.VERCEL_URL}/api/weather/daily_forecast?lat=${lat}&lon=${lon}&appid=${process.env.NEXT_PUBLIC_OPEN_WEATHER_API_KEY}`
`https://${process.env.VERCEL_URL}/api/weather/daily_forecast?lat=${lat}&lon=${lon}&appid=${process.env.NEXT_PUBLIC_OPEN_WEATHER_API_KEY}`
)
if (!data.ok) {
throw new Error("Failed to fetch data")
Expand Down
2 changes: 1 addition & 1 deletion actions/getUVData.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
export const getUVData = async ({ lat, lon }: { lat: string; lon: string }) => {
const data = await fetch(
`${process.env.VERCEL_URL}/api/weather/uv_index?lat=${lat}&lon=${lon}`
`https://${process.env.VERCEL_URL}/api/weather/uv_index?lat=${lat}&lon=${lon}`
)

if (!data.ok) {
Expand Down

0 comments on commit a7d8031

Please sign in to comment.