Skip to content

Commit

Permalink
fix empty mirror check
Browse files Browse the repository at this point in the history
  • Loading branch information
neolynx committed Jul 24, 2024
1 parent deae904 commit 09a44ba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion deb/snapshot.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ type Snapshot struct {

// NewSnapshotFromRepository creates snapshot from current state of repository
func NewSnapshotFromRepository(name string, repo *RemoteRepo) (*Snapshot, error) {
if repo.packageRefs == nil {
if repo.packageRefs == nil || repo.packageRefs.Len() == 0 {
return nil, errors.New("mirror not updated")
}

Expand Down

0 comments on commit 09a44ba

Please sign in to comment.