Skip to content

Commit

Permalink
Added some missing @api.expect and @api.marshal_with
Browse files Browse the repository at this point in the history
  • Loading branch information
noirbizarre committed Jun 2, 2015
1 parent 118e233 commit ee8a399
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions udata/core/dataset/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,8 @@ def get(self, dataset):

@api.secure
@api.doc('update_dataset')
@api.expect(dataset_fields)
@api.marshal_with(dataset_fields)
@api.response(400, 'Validation error')
def put(self, dataset):
'''Update a dataset given its identifier'''
Expand Down
1 change: 1 addition & 0 deletions udata/core/organization/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ def get(self, org):

@api.secure
@api.doc('update_organization')
@api.expect(org_fields)
@api.marshal_with(org_fields)
@api.response(400, 'Validation error')
def put(self, org):
Expand Down
3 changes: 2 additions & 1 deletion udata/core/reuse/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,10 @@ def get(self, reuse):
return reuse

@api.secure
@api.doc('update_reuse', responses={400: 'Validation error'})
@api.doc('update_reuse')
@api.expect(reuse_fields)
@api.marshal_with(reuse_fields)
@api.response(400, 'Validation error')
def put(self, reuse):
'''Update a given reuse'''
if reuse.deleted:
Expand Down

0 comments on commit ee8a399

Please sign in to comment.