Commit 48ad8880 authored by Robin Sonnabend's avatar Robin Sonnabend
Browse files

Fix deleting defaultmetas

/close #175
parent c2e4a969
......@@ -1279,7 +1279,7 @@ def edit_defaultmeta(defaultmeta):
def delete_defaultmeta(defaultmeta):
name = defaultmeta.name
type_id = defaultmeta.protocoltype.id
db.session.delete(meta)
db.session.delete(defaultmeta)
db.session.commit()
flash("Metadatenfeld '{}' gelöscht.".format(name), "alert-success")
return redirect(request.args.get("next") or url_for("show_type", protocoltype_id=type_id))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment