mirror of
https://github.com/murdos/musicbrainz-userscripts
synced 2024-11-10 13:14:16 +00:00
discogs: simplify code
This commit is contained in:
parent
419f623ef9
commit
1f55960600
1 changed files with 6 additions and 4 deletions
|
@ -687,13 +687,15 @@ function parseDiscogsRelease(data) {
|
|||
// Create release if needed
|
||||
var discindex = releaseNumber-1;
|
||||
if (!release.discs[discindex]) {
|
||||
release.discs.push(new Object());
|
||||
release.discs[discindex].tracks = [];
|
||||
release.discs[discindex].format = release_formats[discindex];
|
||||
var newdisc = {
|
||||
tracks: [],
|
||||
format: release_formats[discindex],
|
||||
};
|
||||
if (heading) {
|
||||
release.discs[discindex].title = heading;
|
||||
newdisc.title = heading;
|
||||
heading = "";
|
||||
}
|
||||
release.discs.push(newdisc);
|
||||
}
|
||||
|
||||
// Track number (only for Vinyl and Cassette)
|
||||
|
|
Loading…
Reference in a new issue