8000 Release v3.1 by jacebrowning · Pull Request #155 · flask-api/flask-api · GitHub
[go: up one dir, main page]

Skip to content

Release v3.1 #155

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 18 commits into from
Jun 5, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
clean python 2 compat codes
  • Loading branch information
auvipy authored Sep 1, 2021
commit 00f3542a703a537dffe973e033c5593f2a4337f7
6 changes: 2 additions & 4 deletions flask_api/renderers.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# coding: utf8
from __future__ import unicode_literals
from flask import request, render_template, current_app
from flask.globals import _request_ctx_stack
from flask_api.mediatypes import MediaType
Expand Down Expand Up @@ -35,7 +33,7 @@ def convert_to_title(name):
return name.capitalize()


class BaseRenderer(object):
class BaseRenderer:
media_type = None
charset = 'utf-8'
handles_empty_responses = False
Expand All @@ -60,7 +58,7 @@ def render(self, data, media_type, **options):
return json.dumps(data, cls=current_app.json_encoder, ensure_ascii=False, indent=indent)


class HTMLRenderer(object):
class HTMLRenderer:
media_type = 'text/html'
charset = 'utf-8'

Expand Down
0