mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-01-12 03:21:33 +00:00
fix empty mirror check
This commit is contained in:
@@ -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")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user