Merge "Don't raise not found in delete raw template"

This commit is contained in:
Zuul 2019-12-05 06:20:39 +00:00 committed by Gerrit Code Review
commit 2becc6b273
1 changed files with 5 additions and 1 deletions

View File

@ -142,7 +142,11 @@ def raw_template_update(context, template_id, values):
def raw_template_delete(context, template_id):
raw_template = raw_template_get(context, template_id)
try:
raw_template = raw_template_get(context, template_id)
except exception.NotFound:
# Ignore not found
return
raw_tmpl_files_id = raw_template.files_id
session = context.session
with session.begin(subtransactions=True):