summaryrefslogtreecommitdiffstats
path: root/editor/code_editor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/code_editor.cpp')
-rw-r--r--editor/code_editor.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/editor/code_editor.cpp b/editor/code_editor.cpp
index 70747b4956..9e1a5f2d43 100644
--- a/editor/code_editor.cpp
+++ b/editor/code_editor.cpp
@@ -1408,9 +1408,9 @@ Variant CodeTextEditor::get_edit_state() {
state["bookmarks"] = text_editor->get_bookmarks_array();
state["syntax_highlighter"] = TTR("Standard");
- SyntaxHighlighter *syntax_highlighter = text_editor->_get_syntax_highlighting();
- if (syntax_highlighter) {
- state["syntax_highlighter"] = syntax_highlighter->get_name();
+ Ref<SyntaxHighlighter> syntax_highlighter = text_editor->get_syntax_highlighting();
+ if (syntax_highlighter.is_valid()) {
+ state["syntax_highlighter"] = syntax_highlighter->_get_name();
}
return state;