1
0
Fork 0

Disable raid saving

This commit is contained in:
Andrew Tomaka 2015-04-29 09:42:36 -04:00
parent c9e113e312
commit c8c5f3d60c
1 changed files with 11 additions and 9 deletions

20
app.rb
View File

@ -18,17 +18,19 @@ get '/' do
end end
post '/' do post '/' do
response['Access-Control-Allow-Origin'] = 'http://trugul.com' #response['Access-Control-Allow-Origin'] = 'http://trugul.com'
@raid = Raid.new(params[:raid]) #@raid = Raid.new(params[:raid])
if @raid.save #if @raid.save
content_type :json # content_type :json
{ :message => 'Raid saved' }.to_json # { :message => 'Raid saved' }.to_json
else #else
content_type :json # content_type :json
{ :message => 'Raid failed to save' }.to_json # { :message => 'Raid failed to save' }.to_json
end #end
content_type :json
{ :message => 'Raid saving no longer available' }.to_json
end end
get '/bossfight' do get '/bossfight' do