mirror of
https://pagure.io/fm-orchestrator.git
synced 2026-04-13 20:10:05 +08:00
Get empty string if Content-Type is not in headers
This commit is contained in:
@@ -98,7 +98,7 @@ class ModuleBuildAPI(MethodView):
|
||||
username, conf.allowed_groups, groups))
|
||||
|
||||
kwargs = {"username": username}
|
||||
module = (self.post_file(**kwargs) if "multipart/form-data" in request.headers.get("Content-Type") else
|
||||
module = (self.post_file(**kwargs) if "multipart/form-data" in request.headers.get("Content-Type", "") else
|
||||
self.post_scm(**kwargs))
|
||||
|
||||
return jsonify(module.json()), 201
|
||||
|
||||
Reference in New Issue
Block a user