Преглед изворни кода

refactor: take min value for gte check

refactor to 47734879482a89068286cbd79f63b00db46ebff4

we don't use min_value here anyways because of the Given check, but this is cleaner.
sschmid пре 5 година
родитељ
комит
2fc728f92c
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      src/MusicalScore/ScoreIO/MusicSheetReader.ts

+ 1 - 1
src/MusicalScore/ScoreIO/MusicSheetReader.ts

@@ -571,7 +571,7 @@ export class MusicSheetReader /*implements IMusicSheetReader*/ {
                     const creditJustify: string = creditChild.attribute("justify")?.value;
                     const creditY: string = creditChild.attribute("default-y")?.value;
                     const creditYGiven: boolean = creditY !== undefined && creditY !== null;
-                    const creditYInfo: number = creditYGiven ? parseFloat(creditY) : -1;
+                    const creditYInfo: number = creditYGiven ? parseFloat(creditY) : Number.MIN_VALUE;
                     if (creditYGiven && creditYInfo > systemYCoordinates) {
                         if (!this.musicSheet.Title) {
                             const creditSize: string = creditChild.attribute("font-size").value;