about summary refs log tree commit diff
path: root/app/javascript/mastodon/reducers/statuses.js
diff options
context:
space:
mode:
authorabcang <abcang1015@gmail.com>2017-09-13 17:24:33 +0900
committerEugen Rochko <eugen@zeonfederated.com>2017-09-13 10:24:33 +0200
commit60944d5dca0f25c668db00c0d84910f1dddc2a12 (patch)
tree570c9b355452fac6baf822dcdf8eac933d97cf4a /app/javascript/mastodon/reducers/statuses.js
parent081f907f909c5c8d0993dd7f4f8e7a945a6b1623 (diff)
Fix height cache (#4909)
Diffstat (limited to 'app/javascript/mastodon/reducers/statuses.js')
-rw-r--r--app/javascript/mastodon/reducers/statuses.js18
1 files changed, 0 insertions, 18 deletions
diff --git a/app/javascript/mastodon/reducers/statuses.js b/app/javascript/mastodon/reducers/statuses.js
index eec2a5f16..7f906bef6 100644
--- a/app/javascript/mastodon/reducers/statuses.js
+++ b/app/javascript/mastodon/reducers/statuses.js
@@ -15,8 +15,6 @@ import {
   CONTEXT_FETCH_SUCCESS,
   STATUS_MUTE_SUCCESS,
   STATUS_UNMUTE_SUCCESS,
-  STATUS_SET_HEIGHT,
-  STATUSES_CLEAR_HEIGHT,
 } from '../actions/statuses';
 import {
   TIMELINE_REFRESH_SUCCESS,
@@ -95,18 +93,6 @@ const filterStatuses = (state, relationship) => {
   return state;
 };
 
-const setHeight = (state, id, height) => {
-  return state.update(id, ImmutableMap(), map => map.set('height', height));
-};
-
-const clearHeights = (state) => {
-  state.forEach(status => {
-    state = state.deleteIn([status.get('id'), 'height']);
-  });
-
-  return state;
-};
-
 const initialState = ImmutableMap();
 
 export default function statuses(state = initialState, action) {
@@ -148,10 +134,6 @@ export default function statuses(state = initialState, action) {
     return deleteStatus(state, action.id, action.references);
   case ACCOUNT_BLOCK_SUCCESS:
     return filterStatuses(state, action.relationship);
-  case STATUS_SET_HEIGHT:
-    return setHeight(state, action.id, action.height);
-  case STATUSES_CLEAR_HEIGHT:
-    return clearHeights(state);
   default:
     return state;
   }