Skip to content
Snippets Groups Projects
Commit 48818fde authored by Manish Tomar's avatar Manish Tomar
Browse files

Remove err nil check


since type checking nil will not panic and return appropriately

Signed-off-by: default avatarManish Tomar <manish.tomar@docker.com>
parent da8db466
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -98,15 +98,13 @@ func MarkAndSweep(ctx context.Context, storageDriver driver.StorageDriver, regis
return nil
})
 
if err != nil {
// In certain situations such as unfinished uploads, deleting all
// tags in S3 or removing the _manifests folder manually, this
// error may be of type PathNotFound.
//
// In these cases we can continue marking other manifests safely.
if _, ok := err.(driver.PathNotFoundError); ok {
return nil
}
// In certain situations such as unfinished uploads, deleting all
// tags in S3 or removing the _manifests folder manually, this
// error may be of type PathNotFound.
//
// In these cases we can continue marking other manifests safely.
if _, ok := err.(driver.PathNotFoundError); ok {
return nil
}
 
return err
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment