-
Notifications
You must be signed in to change notification settings - Fork 0
Changes in engine support due to review #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes in engine support due to review #1
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
@@tempfile = Tempfile.new("tailwind.application.css") | ||
|
||
# Write content to tempfile | ||
engines_roots.each do |root| | ||
@@tempfile.write("@import \"#{root}\";\n") | ||
end | ||
@@tempfile.write("\n@import \"#{rails_root.join('app/assets/tailwind/application.css')}\";\n") | ||
@@tempfile.flush | ||
@@tempfile.close | ||
|
||
@@tempfile.path |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using a class variable for temporary file storage may lead to thread-safety issues if compile_command is invoked concurrently. Consider using a method-local variable or thread-local storage for the tempfile.
@@tempfile = Tempfile.new("tailwind.application.css") | |
# Write content to tempfile | |
engines_roots.each do |root| | |
@@tempfile.write("@import \"#{root}\";\n") | |
end | |
@@tempfile.write("\n@import \"#{rails_root.join('app/assets/tailwind/application.css')}\";\n") | |
@@tempfile.flush | |
@@tempfile.close | |
@@tempfile.path | |
tempfile = Tempfile.new("tailwind.application.css") | |
# Write content to tempfile | |
engines_roots.each do |root| | |
tempfile.write("@import \"#{root}\";\n") | |
end | |
tempfile.write("\n@import \"#{rails_root.join('app/assets/tailwind/application.css')}\";\n") | |
tempfile.flush | |
tempfile.close | |
tempfile.path |
Copilot uses AI. Check for mistakes.
Tempfile handling should not be manual. |
No description provided.