Skip to content

Commit

Permalink
A Resource must be a struct that implements the Resource interface
Browse files Browse the repository at this point in the history
  • Loading branch information
joseustra committed Jun 21, 2016
1 parent 7b0f263 commit d9ee0e7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion resource.go
Expand Up @@ -16,7 +16,7 @@ type Resource interface {
}

// GetResource unmarshal the request body and return the resource
func GetResource(req *http.Request, resource interface{}) {
func GetResource(req *http.Request, resource Resource) {
body, _ := ioutil.ReadAll(req.Body)

if IsJSONAPI(req) {
Expand Down

0 comments on commit d9ee0e7

Please sign in to comment.