Fix duplicate task list shown
This commit is contained in:
parent
1e090c3c3c
commit
fb62e3392a
|
@ -169,6 +169,7 @@ export function hideTaskListSuccess( taskList ) {
|
||||||
return {
|
return {
|
||||||
type: TYPES.HIDE_TASK_LIST_SUCCESS,
|
type: TYPES.HIDE_TASK_LIST_SUCCESS,
|
||||||
taskList,
|
taskList,
|
||||||
|
taskListId: taskList.id,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -191,6 +192,7 @@ export function unhideTaskListSuccess( taskList ) {
|
||||||
return {
|
return {
|
||||||
type: TYPES.UNHIDE_TASK_LIST_SUCCESS,
|
type: TYPES.UNHIDE_TASK_LIST_SUCCESS,
|
||||||
taskList,
|
taskList,
|
||||||
|
taskListId: taskList.id,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -246,7 +246,10 @@ export const ActivityPanel = ( { isEmbedded, query } ) => {
|
||||||
if ( currentLocation !== homescreenLocation ) {
|
if ( currentLocation !== homescreenLocation ) {
|
||||||
// Ensure that if the user is trying to get to the task list they can see it even if
|
// Ensure that if the user is trying to get to the task list they can see it even if
|
||||||
// it was dismissed.
|
// it was dismissed.
|
||||||
if ( setupTaskListHidden === 'no' ) {
|
if (
|
||||||
|
setupTaskListHidden === 'no' ||
|
||||||
|
setupTaskListHidden === false
|
||||||
|
) {
|
||||||
redirectToHomeScreen();
|
redirectToHomeScreen();
|
||||||
} else {
|
} else {
|
||||||
unhideTaskList( 'setup' ).then( redirectToHomeScreen );
|
unhideTaskList( 'setup' ).then( redirectToHomeScreen );
|
||||||
|
|
Loading…
Reference in New Issue