これが私のfaxattach.rb
コードです:
require 'sinatra'
require 'docsplit'
require './sinatra/faxattach_helpers'
class FaxAttach < Sinatra::Base
helpers Sinatra::FaxAttachHelpers
get '/*' do
"hello world"
status 405
end
put '/*' do
status 405
end
patch '/*' do
status 405
end
delete '/*' do
status 405
end
options '/*' do
status 405
end
link '/*' do
status 405
end
unlink '/*' do
status 405
end
post '/process' do
path = params[:path]
begin
debugger
file = test_download path
rescue
status 404
end
debugger
code = extractCode file
code
end
end
curl を使用して /process への投稿リクエストを行っていますがcurl --data "path=URL_HERE" localhost:4567/process
、何らかの理由で取得しています: Sinatra doesn't know this ditty
。post /process
それは私が明らかに持っているを入れるように言っています。
何か案は?