chore: remove unused method

This commit is contained in:
EnixCoda 2020-06-20 19:17:23 +08:00
parent 6043fe79ec
commit 9050313ad1
No known key found for this signature in database
GPG key ID: 0C1A07377913A1DD
2 changed files with 0 additions and 8 deletions

View file

@ -34,11 +34,6 @@ const RawFileExplorer: React.FC<Props & ConnectorState> = function RawFileExplor
val: { compressSingletonFolder },
} = useConfigs()
React.useEffect(() => {
const { init } = props
init()
}, [])
React.useEffect(() => {
const { setUpTree, treeRoot, metaData } = props
setUpTree({ treeRoot, metaData, compressSingletonFolder })

View file

@ -20,7 +20,6 @@ export type ConnectorState = {
searchKey: string
searched: boolean // derived state from searchKey, = !!searchKey
init: GetCreatedMethod<typeof init>
execAfterRender: GetCreatedMethod<typeof execAfterRender>
handleKeyDown: GetCreatedMethod<typeof handleKeyDown>
search: GetCreatedMethod<typeof search>
@ -57,8 +56,6 @@ let visibleNodesGenerator: VisibleNodesGenerator
type BoundMethodCreator<Args extends any[] = []> = MethodCreator<Props, ConnectorState, Args>
export const init: BoundMethodCreator = dispatch => () => dispatch.set({ state: 'pulling' })
export const setUpTree: BoundMethodCreator<[
Pick<Props, 'treeRoot' | 'metaData'> & Pick<Config, 'compressSingletonFolder'>,
]> = dispatch => async ({ treeRoot, metaData, compressSingletonFolder }) => {