From 2d640945a325b833294b823c5eb3758aa028739c Mon Sep 17 00:00:00 2001 From: Nolan Lawson Date: Thu, 15 Feb 2018 22:21:42 -0800 Subject: [PATCH] lint fixup --- routes/_actions/streaming.js | 8 ++++---- routes/_store/instanceObservers.js | 2 -- routes/_store/timelineObservers.js | 1 - 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/routes/_actions/streaming.js b/routes/_actions/streaming.js index ad4474b9..9c4fb862 100644 --- a/routes/_actions/streaming.js +++ b/routes/_actions/streaming.js @@ -6,7 +6,7 @@ import { scheduleIdleTask } from '../_utils/scheduleIdleTask' import throttle from 'lodash/throttle' import { mark, stop } from '../_utils/marks' -async function getReblogIds(instanceName, statusIds) { +async function getReblogIds (instanceName, statusIds) { let reblogIds = await Promise.all(statusIds.map(async timelineItemId => { let status = await database.getStatus(instanceName, timelineItemId) return status.reblog && status.reblog.id @@ -14,7 +14,7 @@ async function getReblogIds(instanceName, statusIds) { return reblogIds.filter(identity) } -async function getExistingItemIdsSet(instanceName, timelineName) { +async function getExistingItemIdsSet (instanceName, timelineName) { let timelineItemIds = store.getForTimeline(instanceName, timelineName, 'timelineItemIds') || [] if (timelineName === 'notifications') { return new Set(timelineItemIds) @@ -56,14 +56,14 @@ const lazilyProcessFreshUpdates = throttle((instanceName, timelineName) => { }) }, 5000) -function processUpdate(instanceName, timelineName, update) { +function processUpdate (instanceName, timelineName, update) { let freshUpdates = store.getForTimeline(instanceName, timelineName, 'freshUpdates') || [] freshUpdates.push(update) store.setForTimeline(instanceName, timelineName, {freshUpdates: freshUpdates}) lazilyProcessFreshUpdates(instanceName, timelineName) } -function processDelete(instanceName, deletion) { +function processDelete (instanceName, deletion) { // TODO } diff --git a/routes/_store/instanceObservers.js b/routes/_store/instanceObservers.js index 6573ebda..0dcdc500 100644 --- a/routes/_store/instanceObservers.js +++ b/routes/_store/instanceObservers.js @@ -3,7 +3,6 @@ import { updateLists } from '../_actions/lists' import { createStream } from '../_actions/streaming' export function instanceObservers (store) { - // stream to watch for home timeline updates and notifications let currentInstanceStream @@ -38,6 +37,5 @@ export function instanceObservers (store) { if (process.env.NODE_ENV !== 'production') { window.currentInstanceStream = currentInstanceStream } - }) } diff --git a/routes/_store/timelineObservers.js b/routes/_store/timelineObservers.js index f7a45029..ece17195 100644 --- a/routes/_store/timelineObservers.js +++ b/routes/_store/timelineObservers.js @@ -2,7 +2,6 @@ import { updateInstanceInfo } from '../_actions/instances' import { createStream } from '../_actions/streaming' export function timelineObservers (store) { - // stream to watch for local/federated/etc. updates. home and notification // updates are handled in timelineObservers.js let currentTimelineStream