Merge pull request #4246 from mattermost/template-selector-fix

Not opening template picker if there are no boards
This commit is contained in:
Scott Bishel 2022-11-28 13:57:19 -07:00 committed by GitHub
commit 24fea1f44e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -163,8 +163,10 @@ const Workspace = (props: Props) => {
setBoardTemplateSelectorOpen(false)
}, [])
const openBoardTemplateSelector = useCallback(() => {
setBoardTemplateSelectorOpen(true)
}, [])
if (board) {
setBoardTemplateSelectorOpen(true)
}
}, [board])
useEffect(() => {
setBoardTemplateSelectorOpen(false)
}, [board, viewId])