Skip to content

Commit

Permalink
Merge pull request #92145 from jsjtxietian/doc-init
Browse files Browse the repository at this point in the history
Prevent add shader uniform doc when DocTool is not inited
  • Loading branch information
akien-mga committed May 21, 2024
2 parents 008fd5f + d1cd0c4 commit 149e3b8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scene/resources/shader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ void Shader::get_shader_uniform_list(List<PropertyInfo> *p_params, bool p_get_gr
}
}
#ifdef TOOLS_ENABLED
if (Engine::get_singleton()->is_editor_hint() && !class_doc.name.is_empty() && p_params) {
if (EditorHelp::get_doc_data() != nullptr && Engine::get_singleton()->is_editor_hint() && !class_doc.name.is_empty() && p_params) {
EditorHelp::get_doc_data()->add_doc(class_doc);
}
#endif
Expand Down

0 comments on commit 149e3b8

Please sign in to comment.