Fix wrong hook name

GitOrigin-RevId: 58f98b508cf650a6ecab38772faf9ecd38c9a7bc
This commit is contained in:
M Fahru 2023-01-03 10:29:09 -07:00 committed by Copybot
parent f2060b35ad
commit 10bb724197
2 changed files with 3 additions and 3 deletions

View file

@ -1,6 +1,6 @@
import { createContext, useContext, useMemo } from 'react'
import type { PropsWithChildren } from 'react'
import useSetProjectWideSettings from '../hooks/use-set-project-wide-settings'
import useProjectWideSettings from '../hooks/use-project-wide-settings'
import useUserWideSettings from '../hooks/use-user-wide-settings'
import useProjectWideSettingsSocketListener from '../hooks/use-project-wide-settings-socket-listener'
import type { ProjectSettingsScope, UserSettingsScope } from '../utils/api'
@ -48,7 +48,7 @@ export function ProjectSettingsProvider({
setRootDocId,
spellCheckLanguage,
setSpellCheckLanguage,
} = useSetProjectWideSettings()
} = useProjectWideSettings()
const {
autoComplete,

View file

@ -6,7 +6,7 @@ import { ProjectSettingsScope, saveProjectSettings } from '../utils/api'
import useSetRootDocId from './use-set-root-doc-id'
import useSetSpellCheckLanguage from './use-set-spell-check-language'
export default function useSetProjectWideSettings() {
export default function useProjectWideSettings() {
// The value will be undefined on mount
const [project, setProject] = useScopeValue<ProjectSettingsScope | undefined>(
'project',