From 415fc275399e73edc257a1584cb34b4c76d38bf7 Mon Sep 17 00:00:00 2001 From: yflory Date: Tue, 11 Feb 2020 14:08:11 +0100 Subject: [PATCH] Pin todo and trim its history --- www/common/outer/async-store.js | 6 +++++- www/common/outer/history.js | 6 ++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/www/common/outer/async-store.js b/www/common/outer/async-store.js index 3ed2f5084..43fa364bc 100644 --- a/www/common/outer/async-store.js +++ b/www/common/outer/async-store.js @@ -166,7 +166,7 @@ define([ // It now includes channels from shared folders var list = store.manager.getChannelsList('pin'); - // Get the avatar + // Get the avatar & profile var profile = store.proxy.profile; if (profile) { var profileChan = profile.edit ? Hash.hrefToHexChannelId('/profile/#' + profile.edit, null) : null; @@ -175,6 +175,10 @@ define([ if (avatarChan) { list.push(avatarChan); } } + if (store.proxy.todo) { + list.push(Hash.hrefToHexChannelId('/todo/#' + store.proxy.todo, null)); + } + if (store.proxy.friends) { var fList = Messaging.getFriendChannelsList(store.proxy); list = list.concat(fList); diff --git a/www/common/outer/history.js b/www/common/outer/history.js index efb39e11c..269821680 100644 --- a/www/common/outer/history.js +++ b/www/common/outer/history.js @@ -24,6 +24,12 @@ define([ if (profileChan) { channels.push(profileChan); } } + // Todo + if (ctx.store.proxy.todo) { + channels.push(Hash.hrefToHexChannelId('/todo/#' + ctx.store.proxy.todo, null)); + } + + // Mailboxes var mailboxes = ctx.store.proxy.mailboxes; if (mailboxes) {