Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/photos.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCorentin Mors <corentin.mors@dashlane.com>2020-10-27 10:51:42 +0300
committerJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>2020-11-15 11:37:53 +0300
commit34b1aa6c8044d26a8d533634c0a8ba558826ff5c (patch)
tree0ed6c5dbfa48338c2b2682e2196cab8e42549974 /src
parentda4114334d61d1e6a978f7fd180fe0afc0a035cf (diff)
Redirect when there is no tags app enable
Signed-off-by: Corentin Mors <corentin.mors@dashlane.com>
Diffstat (limited to 'src')
-rw-r--r--src/router/index.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/router/index.js b/src/router/index.js
index 93ae68bb..3157058d 100644
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -25,6 +25,7 @@ import Router from 'vue-router'
import Vue from 'vue'
import isMapsInstalled from '../services/IsMapsInstalled'
+import areTagsInstalled from '../services/AreTagsInstalled'
import { videoMimes } from '../services/AllowedMimes'
const Albums = () => import('../views/Albums')
@@ -58,7 +59,7 @@ export default new Router({
{
path: '/',
component: Timeline,
- name: 'root',
+ name: 'timeline',
props: route => ({
rootTitle: t('photos', 'Your photos'),
}),
@@ -108,6 +109,7 @@ export default new Router({
path: '/tags/:path*',
component: Tags,
name: 'tags',
+ redirect: !areTagsInstalled ? { name: 'timeline' } : null,
props: route => ({
path: `${route.params.path ? route.params.path : ''}`,
// if path is empty