diff --git a/scripts/generate_graphql_api_content.rb b/scripts/generate_graphql_api_content.rb index 6d65611959..3162ae7c89 100644 --- a/scripts/generate_graphql_api_content.rb +++ b/scripts/generate_graphql_api_content.rb @@ -33,7 +33,7 @@ schema_type_data["kind"].to_s.downcase end - Dir.mkdir("#{schemas_dir}/#{sub_dir}") unless File.exists?("#{schemas_dir}/#{sub_dir}") + Dir.mkdir("#{schemas_dir}/#{sub_dir}") unless File.exist?("#{schemas_dir}/#{sub_dir}") File.write("#{schemas_dir}/#{sub_dir}/#{name.downcase}.md", render_page(schema_type_data, sub_dir.capitalize.pluralize)) end end