lib/learn_submit/submission.rb in learn-submit-1.0.4 vs lib/learn_submit/submission.rb in learn-submit-1.0.5
- old
+ new
@@ -17,12 +17,10 @@
def create
setup_tmp_file
commit_and_push!
submit!
-
- cleanup_tmp_file
end
def setup_tmp_file
FileUtils.touch(file_path)
File.write(file_path, '')
@@ -67,15 +65,17 @@
end
case pr_response.status
when 200
puts "Done."
+ File.write(file_path, 'Done.')
exit
when 404
puts 'Sorry, it seems like there was a problem connecting with Learn. Please try again.'
exit
else
puts pr_response.message
+ File.write(file_path, 'Done.')
exit
end
end
end
end