mirror of
https://git.selfprivacy.org/SelfPrivacy/selfprivacy-rest-api.git
synced 2024-11-28 23:11:29 +00:00
Added response encoding
This commit is contained in:
parent
0f9947a274
commit
b82a5fe3d0
6
main.py
6
main.py
|
@ -19,10 +19,8 @@ def getDkimKey():
|
|||
domain = domain.rstrip("\n")
|
||||
catProcess = subprocess.Popen(["cat", "/var/dkim/" + domain + ".selector.txt"], stdout=subprocess.PIPE)
|
||||
dkim = catProcess.communicate()[0]
|
||||
#dkim = str(dkim, "utf-8")
|
||||
#dkim = base64.b64encode(dkim)
|
||||
print(dkim)
|
||||
return "0"
|
||||
dkim = base64.b64encode(dkim)
|
||||
return jsonify(dkim)
|
||||
@app.route("/pythonVersion", methods=["GET"])
|
||||
def getPythonVersion():
|
||||
pythonVersion = subprocess.check_output(["python","--version"])
|
||||
|
|
Loading…
Reference in a new issue