From d258913c08138738c9ddee618c6f8a66ca9e3d3e Mon Sep 17 00:00:00 2001 From: greta Date: Fri, 13 May 2022 10:43:01 +0200 Subject: [PATCH] Change the timeout value to fit the dialogs Signed-off-by: greta --- src/store/constants.js | 4 +++- src/store/outbox/actions.js | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/store/constants.js b/src/store/constants.js index 7db5d0dd00..639b18455f 100644 --- a/src/store/constants.js +++ b/src/store/constants.js @@ -19,8 +19,10 @@ * along with this program. If not, see . */ +import { TOAST_UNDO_TIMEOUT } from '@nextcloud/dialogs' + export const UNIFIED_ACCOUNT_ID = 0 export const UNIFIED_INBOX_ID = 'unified' export const PRIORITY_INBOX_ID = 'priority' export const PAGE_SIZE = 20 -export const UNDO_DELAY = 7 * 1000 +export const UNDO_DELAY = TOAST_UNDO_TIMEOUT diff --git a/src/store/outbox/actions.js b/src/store/outbox/actions.js index ccfd58604c..a6623197d9 100644 --- a/src/store/outbox/actions.js +++ b/src/store/outbox/actions.js @@ -24,8 +24,8 @@ import * as OutboxService from '../../service/OutboxService' import logger from '../../logger' import { showError, showUndo } from '@nextcloud/dialogs' import { translate as t } from '@nextcloud/l10n' -import { UNDO_DELAY } from '../constants' import { html, plain } from '../../util/text' +import { UNDO_DELAY } from '../constants' export default { async fetchMessages({ getters, commit }) {