Skip to content

Commit

Permalink
Fix CreateLocation.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
aelassas committed Nov 30, 2024
1 parent f7f6267 commit 7e9891f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions backend/src/pages/CreateLocation.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useState } from 'react'
import { useNavigate } from 'react-router-dom'
// import { useNavigate } from 'react-router-dom'
import {
Input,
InputLabel,
Expand All @@ -25,7 +25,7 @@ import PositionInput from '@/components/PositionInput'
import '@/assets/css/create-location.css'

const CreateLocation = () => {
const navigate = useNavigate()
// const navigate = useNavigate()

const [visible, setVisible] = useState(false)
const [names, setNames] = useState<bookcarsTypes.LocationName[]>([])
Expand Down Expand Up @@ -215,7 +215,8 @@ const CreateLocation = () => {
if (image) {
await LocationService.deleteTempImage(image)
}
navigate('/locations')
// navigate('/locations')
window.location.href = '/locations'
}}
>
{commonStrings.CANCEL}
Expand Down

0 comments on commit 7e9891f

Please sign in to comment.