added a method that we will later use to serialize the raw paste into json so we can ship it to a DB

This commit is contained in:
booboy 2018-11-10 04:27:25 -06:00
parent 879a897770
commit ef312d12cf
2 changed files with 4 additions and 2 deletions

View file

@ -13,7 +13,7 @@ def download_pastes(pb)
data_dir = "../data/"
filename = "pastebin_paste_key"
keys.map do |id|
if File.exist?(data_dir + filename)
if File.exist?(data_dir + filename + "_#{id[:keu]}")
puts "#{id[:key]} already exists on your filesystem, skipping..."
else
File.write(data_dir + filename + "_#{id[:key]}", pb.raw_paste_data(id[:key]))

View file

@ -1,7 +1,9 @@
class PastebinnerError < StandardError
def ArgumentError
end
def ConfigError
end
end