Skip to content

Commit 9d5cf47

Browse files
committed
le sigh
1 parent dd942be commit 9d5cf47

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

app.rb

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,15 @@
22

33
class App < Sinatra::Base
44
before do
5-
puts "body=#{request.body}"
5+
puts "body=#{request.body.read}"
66
end
77

88
get '/get' do
99
'OK'
1010
end
1111

1212
post '/post' do
13+
request.body.rewind
1314
if request.body.read == "POSTDATA"
1415
'OK'
1516
else

0 commit comments

Comments
 (0)