code now follows the PEP8 standard
This commit is contained in:
+9
-7
@@ -4,22 +4,24 @@ from flask_sqlalchemy import SQLAlchemy
|
||||
app = Flask(__name__)
|
||||
app.config.from_object('config')
|
||||
|
||||
|
||||
def on_404(e):
|
||||
return jsonify(dict(error='Not found')), 404
|
||||
return jsonify(dict(error='Not found')), 404
|
||||
|
||||
app.errorhandler(404)(on_404)
|
||||
|
||||
#SQLAlchemy
|
||||
# SQLAlchemy
|
||||
db = SQLAlchemy(app)
|
||||
|
||||
from api.views import designers
|
||||
app.register_blueprint(designers.mod)
|
||||
|
||||
|
||||
@app.route("/")
|
||||
def index():
|
||||
data = {
|
||||
"info": {
|
||||
"api_version": "0.0.1"
|
||||
data = {
|
||||
"info": {
|
||||
"api_version": "0.0.1"
|
||||
}
|
||||
}
|
||||
}
|
||||
return jsonify(data)
|
||||
return jsonify(data)
|
||||
|
||||
Reference in New Issue
Block a user