1
0
mirror of https://github.com/clementine-player/Clementine synced 2024-12-16 19:31:02 +01:00

Fix a crash when loading an old playlist containing Radio items after an upgrade to a version where they're Internet items

This commit is contained in:
David Sansome 2011-07-18 22:20:22 +00:00
parent 05ac1e1afc
commit 69bd5555e7
2 changed files with 2 additions and 3 deletions

View File

@ -33,7 +33,6 @@ class InternetPlaylistItem : public PlaylistItem {
Options options() const;
bool InitFromQuery(const SqlRow& query);
void BindToQuery(QSqlQuery *query) const;
Song Metadata() const;
QUrl Url() const;

View File

@ -41,8 +41,8 @@ PlaylistItem* PlaylistItem::NewFromType(const QString& type) {
return new JamendoPlaylistItem(type);
if (type == "Stream" || type == "File")
return new SongPlaylistItem(type);
if (type == "Internet")
return new InternetPlaylistItem(type);
if (type == "Internet" || type == "Radio")
return new InternetPlaylistItem("Internet");
qLog(Warning) << "Invalid PlaylistItem type:" << type;
return NULL;