diff --git a/endpoints/clients.py b/endpoints/clients.py index f1a441938fc72a964a22195fa33fa222f054c0e2..cc4018be3379f31a0af48bb59662507e1d8d087a 100644 --- a/endpoints/clients.py +++ b/endpoints/clients.py @@ -98,9 +98,9 @@ clients_file = ClientsFile() # Client class Client(Resource): - @marshal_with(resource_fields) def get(self, client_id): client = clients_file.find(client_id) + del client['secret'] if not client: abort(404, message="No client with id: {}".format(client_id)) return client diff --git a/endpoints/notify.py b/endpoints/notify.py index 8c683859c6ee75bc112b7bb95d035a5450bee1d2..96c54e34be6ef15e1f565e73b0e62df03a63eb57 100644 --- a/endpoints/notify.py +++ b/endpoints/notify.py @@ -1,5 +1,5 @@ -from flask_restful import Resource, reqparse, abort, fields, marshal_with -from marshmallow import Schema, field +from flask_restful import Resource, reqparse, abort +from marshmallow import Schema, fields import json class NotifySchema(Schema): diff --git a/endpoints/receive.py b/endpoints/receive.py index 6567b0d1eb8cdca6a2faf7fcc605d43d1a3219ec..2f86d7af30f1054c26e9e16a785d7354d2e8b25d 100644 --- a/endpoints/receive.py +++ b/endpoints/receive.py @@ -1,4 +1,4 @@ -from flask_restful import Resource, request, abort, fields +from flask_restful import Resource, request, abort from marshmallow import Schema, fields import pika import json diff --git a/endpoints/send.py b/endpoints/send.py index 31e38d96548d45fa8190846d6f2505233f80556d..8cbfda15a46ebd1c1cb31c7ed0cf041099bedd21 100644 --- a/endpoints/send.py +++ b/endpoints/send.py @@ -1,5 +1,5 @@ -from flask_restful import Resource, reqparse, abort, fields, marshal_with -from marshmallow import Schema, field +from flask_restful import Resource, reqparse, abort +from marshmallow import Schema, fields import json class SendSchema(Schema):