mirror of https://github.com/vector-im/riot-web
Use consistent indentation and break;s in TagOrderStore switch
parent
a120335130
commit
3e532e3722
|
@ -65,13 +65,14 @@ class TagOrderStore extends Store {
|
|||
break;
|
||||
}
|
||||
// Initialise the state such that if account data is unset, default to joined groups
|
||||
case 'GroupActions.fetchJoinedGroups.success':
|
||||
case 'GroupActions.fetchJoinedGroups.success': {
|
||||
this._setState({
|
||||
joinedGroupIds: payload.result.groups.sort(), // Sort lexically
|
||||
hasFetchedJoinedGroups: true,
|
||||
});
|
||||
this._updateOrderedTags();
|
||||
break;
|
||||
}
|
||||
// Puts payload.tag at payload.targetTag, placing the targetTag before or after the tag
|
||||
case 'order_tag': {
|
||||
if (!this._state.orderedTags ||
|
||||
|
@ -90,10 +91,10 @@ class TagOrderStore extends Store {
|
|||
...orderedTags.slice(newIndex),
|
||||
];
|
||||
this._setState({orderedTags});
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
_updateOrderedTags() {
|
||||
this._setState({
|
||||
|
|
Loading…
Reference in New Issue