diff --git a/main.go b/main.go index 0eb7382..3afe941 100644 --- a/main.go +++ b/main.go @@ -658,7 +658,9 @@ func getOrphanReplacement(webPath string) (*webOrphanImage, error) { } parent, err := idForDirectoryPath(tx, path[:len(path)-1], false) - if err != nil { + if errors.Is(err, sql.ErrNoRows) { + return nil, nil + } else if err != nil { return nil, err }