Skip to content

Commit

Permalink
Prevent add shader uniform doc when DocTool is not inited
Browse files Browse the repository at this point in the history
  • Loading branch information
jsjtxietian committed May 20, 2024
1 parent daa81bb commit d1cd0c4
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 d1cd0c4

Please sign in to comment.