mirror of
https://github.com/rojo-rbx/rojo.git
synced 2026-10-20 17:41:37 +00:00
Merge plugin back into main repository (#49)
This commit is contained in:
parent
c8f837d726
commit
6fa925a402
55 changed files with 1742 additions and 36 deletions
20
plugin/src/HttpResponse.lua
Normal file
20
plugin/src/HttpResponse.lua
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
local HttpService = game:GetService("HttpService")
|
||||
|
||||
local HttpResponse = {}
|
||||
HttpResponse.__index = HttpResponse
|
||||
|
||||
function HttpResponse.new(body)
|
||||
local response = {
|
||||
body = body,
|
||||
}
|
||||
|
||||
setmetatable(response, HttpResponse)
|
||||
|
||||
return response
|
||||
end
|
||||
|
||||
function HttpResponse:json()
|
||||
return HttpService:JSONDecode(self.body)
|
||||
end
|
||||
|
||||
return HttpResponse
|
||||
Loading…
Add table
Add a link
Reference in a new issue