Change historyOfTypeIsValid condition
This commit is contained in:
committed by
Shawn Erquhart
parent
9e5f42e772
commit
fba6929301
@ -21,7 +21,8 @@ function changeHistory(change, type) {
|
|||||||
*/
|
*/
|
||||||
const next = historyOfType.first();
|
const next = historyOfType.first();
|
||||||
const historyOfTypeIsValid = historyOfType.size > 1
|
const historyOfTypeIsValid = historyOfType.size > 1
|
||||||
|| ( next && next.length > 1 && next[0].type !== 'set_selection' );
|
|| (next && next.length > 1)
|
||||||
|
|| (next && next[0] && next[0].type !== 'set_selection');
|
||||||
|
|
||||||
if (historyOfTypeIsValid) {
|
if (historyOfTypeIsValid) {
|
||||||
change[type]();
|
change[type]();
|
||||||
|
Reference in New Issue
Block a user