mirror of
https://github.com/atom/atom.git
synced 2026-02-07 21:25:05 -05:00
Don't remeasure invalid block decorations
This fixes an uncaught exception that was being thrown after invalidating a marker and resizing the editor.
This commit is contained in:
@@ -286,7 +286,8 @@ class TextEditorComponent {
|
||||
const decorations = this.props.model.getDecorations()
|
||||
for (var i = 0; i < decorations.length; i++) {
|
||||
const decoration = decorations[i]
|
||||
if (decoration.getProperties().type === 'block') {
|
||||
const marker = decoration.getMarker()
|
||||
if (marker.isValid() && decoration.getProperties().type === 'block') {
|
||||
this.blockDecorationsToMeasure.add(decoration)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user