Skip to content

Commit

Permalink
style: format code with Autopep8, Black, ClangFormat, dotnet-format, …
Browse files Browse the repository at this point in the history
…Go fmt, Gofumpt, Google Java Format, isort, Ktlint, PHP CS Fixer, Prettier, RuboCop, Ruff Formatter, Rustfmt, Scalafmt, StandardJS, StandardRB, swift-format and Yapf

This commit fixes the style issues introduced in a0333ed according to the output
from Autopep8, Black, ClangFormat, dotnet-format, Go fmt, Gofumpt, Google Java
Format, isort, Ktlint, PHP CS Fixer, Prettier, RuboCop, Ruff Formatter, Rustfmt,
Scalafmt, StandardJS, StandardRB, swift-format and Yapf.

Details: None
  • Loading branch information
deepsource-autofix[bot] authored May 11, 2024
1 parent a0333ed commit 9917583
Showing 1 changed file with 12 additions and 8 deletions.
20 changes: 12 additions & 8 deletions identity_verifier/identity_verifier/api.py
Original file line number Diff line number Diff line change
@@ -1,24 +1,28 @@
from flask import Flask, request, jsonify
from flask import Flask, jsonify, request

from identity_verifier.biometrics import BiometricVerifier

app = Flask(__name__)

@app.route('/verify', methods=['POST'])

@app.route("/verify", methods=["POST"])
def verify():
# Get the image from the request
image = request.files['image'].read()
image = request.files["image"].read()

# Verify the identity
verifier = BiometricVerifier('facial_recognition')
verifier = BiometricVerifier("facial_recognition")
is_verified = verifier.verify(image)

# Return the result
return jsonify({'is_verified': is_verified})
return jsonify({"is_verified": is_verified})

@app.route('/biometrics', methods=['GET'])

@app.route("/biometrics", methods=["GET"])
def biometrics():
# Return a list of available biometric verification methods
return jsonify({'biometrics': ['facial_recognition']})
return jsonify({"biometrics": ["facial_recognition"]})


if __name__ == '__main__':
if __name__ == "__main__":
app.run(debug=True)

0 comments on commit 9917583

Please sign in to comment.