2
레일을 사용하여 서버에 ping을 시도하고 있습니다.레일을 사용하여 서버에 ping을 실행하십시오.
`<main>': undefined method `status' for #<Net::HTTPFound 302 Found readbody=true> (NoMethodError)
이유 :이
Check HTTP Status Code in Rails
하지만이 코드를 실행하는 동안이 오류가,
require 'net/http'
http = Net::HTTP.new('www.google.com',80)
response = http.request_get('/')
p response.status
오류를 발견? 그리고 왜 구글은 302 코드를 돌려 주나요 ?? 그것은 200일까요?