Skip to content

Commit

Permalink
Merge branch 'master' into fufeck_fix_disable-button-delete
Browse files Browse the repository at this point in the history
  • Loading branch information
fufeck authored Aug 7, 2023
2 parents 54129b7 + 11b3894 commit 118dcf0
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 2 deletions.
1 change: 1 addition & 0 deletions components/map/map.js
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,7 @@ function Map({commune, isAddressFormOpen, handleAddressForm}) {
onMouseLeave={handleMouseLeave}
onMouseOut={handleMouseLeave}
onViewportChange={setViewport}
dragRotate={false}
>

<NavControl onViewportChange={setViewport} />
Expand Down
8 changes: 7 additions & 1 deletion pages/dashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,13 @@ function Index({basesLocales, basesLoclesStats}) {
)
}

Index.getInitialProps = async () => {
Index.getInitialProps = async ({res}) => {
if (res) {
res.statusCode = 404
res.end('Not found')
return
}

const basesLocales = await getBasesLocales()
const basesLoclesStats = await getBasesLocalesStats()
const basesLocalesWithoutDemo = basesLocales.filter((b => b.status !== 'demo'))
Expand Down
8 changes: 7 additions & 1 deletion pages/dashboard/departement.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,13 @@ function Departement({departement, filteredCommunesInBAL, basesLocalesDepartemen
)
}

Departement.getInitialProps = async ({query}) => {
Departement.getInitialProps = async ({res, query}) => {
if (res) {
res.statusCode = 404
res.end('Not found')
return
}

const {codeDepartement} = query

const departement = await getDepartement(codeDepartement)
Expand Down

0 comments on commit 118dcf0

Please sign in to comment.