Add extra image check for put_image_checksum
This commit is contained in:
parent
a19035f3b3
commit
5e74edc116
1 changed files with 3 additions and 0 deletions
|
@ -278,6 +278,9 @@ def put_image_checksum(namespace, repository, image_id):
|
|||
|
||||
profile.debug('Looking up repo image')
|
||||
repo_image = model.get_repo_image(namespace, repository, image_id)
|
||||
if not repo_image or not repo_image.storage:
|
||||
abort(404, 'Image not found: %(image_id)s', issue='unknown-image', image_id=image_id)
|
||||
|
||||
uuid = repo_image.storage.uuid
|
||||
|
||||
profile.debug('Looking up repo layer data')
|
||||
|
|
Reference in a new issue