move mockfs DumpDB to db package

This commit is contained in:
sentriz
2023-10-09 21:50:34 +01:00
parent c9a2d2f9ce
commit 66a29f7e93
5 changed files with 502 additions and 501 deletions

View File

@@ -356,7 +356,7 @@ func migratePublicPlaylist(tx *gorm.DB, _ MigrationContext) error {
if !tx.HasTable("playlists") {
return nil
}
return tx.AutoMigrate(_OldPlaylist{}).Error
return tx.AutoMigrate(__OldPlaylist{}).Error
}
func migratePodcastDropUserID(tx *gorm.DB, _ MigrationContext) error {
@@ -495,7 +495,7 @@ func migratePlaylistsToM3U(tx *gorm.DB, ctx MigrationContext) error {
return fmt.Errorf("create playlists store: %w", err)
}
var prevs []*_OldPlaylist
var prevs []*__OldPlaylist
if err := tx.Find(&prevs).Error; err != nil {
return fmt.Errorf("fetch old playlists: %w", err)
}