mirror of
https://github.com/murdos/musicbrainz-userscripts
synced 2024-12-14 04:12:28 +00:00
Issue 89: ignore repeated '.' or '-' in (buggy) track position
http://www.discogs.com/release/1520366 has a track with buggy position, the script is placing the track at the wrong position because of this. 2-.23 Le Carnaval 0:26 2-.23 is now parsed as it was 2-23 This patch shouldn't affect non-buggy track positions.
This commit is contained in:
parent
6a8d60d4a1
commit
075f417376
1 changed files with 1 additions and 1 deletions
|
@ -657,7 +657,7 @@ function parseDiscogsRelease(data) {
|
|||
// A1 or A => Vinyl or Cassette : guess releaseNumber from vinyl side
|
||||
// 1-1 or 1.1 => releaseNumber.trackNumber
|
||||
// 1 => trackNumber
|
||||
var tmp = trackPosition.match(/(\d+|[A-Z])(?:[\.-](\d+))?/i);
|
||||
var tmp = trackPosition.match(/(\d+|[A-Z])(?:[\.-]+(\d+))?/i);
|
||||
if (tmp) {
|
||||
tmp[1] = parseInt(tmp[1], 10);
|
||||
var buggyTrackNumber = false;
|
||||
|
|
Loading…
Reference in a new issue