diff options
| author | Henry Jameson <me@hjkos.com> | 2018-11-26 04:38:44 +0300 |
|---|---|---|
| committer | Henry Jameson <me@hjkos.com> | 2018-11-26 04:38:44 +0300 |
| commit | e06717fd0dfa4b37ebf481d5f4cd7ce8ef0034d0 (patch) | |
| tree | 7f3f7d27ac932e72ec9b5fbdb41b7c8efb210396 /src/modules/statuses.js | |
| parent | 0ca42bd3d63e209f9c1354a30a3123c1f7317579 (diff) | |
| parent | f1a23f2b6edb0858890c82cf42c8b6d835102d56 (diff) | |
Merge remote-tracking branch 'upstream/develop' into feature/scope_preferences
* upstream/develop:
DM timeline: stream new statuses
update-japanese-translation
Add actual user search.
incorporate most translation changes from MR 368
update french translation
Always show dm panel.
Add direct message tab.
api service url
On logout switch to public timeline.
Put oauth text into description.
Display OAuth login on login form button.
Add login form back in.
Linting.
Re-activate registration, use oauth password flow to fetch token.
Fix typo.
Remove gonsole.logg :DD
Fix linting.
Move login to oauth.
Diffstat (limited to 'src/modules/statuses.js')
| -rw-r--r-- | src/modules/statuses.js | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/modules/statuses.js b/src/modules/statuses.js index f980f53d..2c3d2550 100644 --- a/src/modules/statuses.js +++ b/src/modules/statuses.js @@ -41,7 +41,8 @@ export const defaultState = { own: emptyTl(), publicAndExternal: emptyTl(), friends: emptyTl(), - tag: emptyTl() + tag: emptyTl(), + dms: emptyTl() } } @@ -171,6 +172,14 @@ const addNewStatuses = (state, { statuses, showImmediately = false, timeline, us sortTimeline(mentions) } } + if (status.visibility === 'direct') { + const dms = state.timelines.dms + + mergeOrAdd(dms.statuses, dms.statusesObject, status) + dms.newStatusCount += 1 + + sortTimeline(dms) + } } // Decide if we should treat the status as new for this timeline. |
