Fix potential null access in `TextEdit`

This commit is contained in:
A Thousand Ships 2024-04-05 18:36:18 +02:00
parent f4942b7350
commit d4cf294b35
No known key found for this signature in database
GPG Key ID: 2033189A662F8BD7
1 changed files with 1 additions and 1 deletions

View File

@ -8143,7 +8143,7 @@ void TextEdit::_update_gutter_width() {
/* Syntax highlighting. */
Dictionary TextEdit::_get_line_syntax_highlighting(int p_line) {
return syntax_highlighter.is_null() && !setting_text ? Dictionary() : syntax_highlighter->get_line_syntax_highlighting(p_line);
return (syntax_highlighter.is_null() || setting_text) ? Dictionary() : syntax_highlighter->get_line_syntax_highlighting(p_line);
}
/* Deprecated. */