Are repeated almost in every single method of the views. Since the accept_mimetype and payload_mimetype are obtained, and set, in the content_negotiation decorator (which decorates views). Would it be "acceptable" to make said assignation in the decorator? Reasoning:
It is related to the content negotiation, as in it depends from its obtained mimetypes
It would mean the lines of code are not repeated...
Every request requires both loading (args parse and/or data loading) and response handling.
The code lines:
Are repeated almost in every single method of the views. Since the
accept_mimetype
andpayload_mimetype
are obtained, and set, in thecontent_negotiation
decorator (which decorates views). Would it be "acceptable" to make said assignation in the decorator? Reasoning: