Fixededgecasewhereaseverewarninginanonmainlocationcanbreakthesim

This commit is contained in:
BuildTools 2022-03-19 18:59:36 -04:00
parent 897df5203a
commit 015e8d0b59
2 changed files with 3 additions and 3 deletions

View File

@ -30,7 +30,7 @@ function MarqueeMan() {
.marquee('destroy')
.marquee({speed: 170, delayBeforeStart: 1000, pauseOnHover: true, pauseOnCycle: true})
.on('finished', function(){
switchToWarningMarquee(((sidx < weatherInfo.bulletin.severewarnings.length) ? sdix + 1 : 0))
switchToWarningMarquee(((sidx < weatherInfo.bulletin.severewarnings.length) ? sidx + 1 : 0))
})
} else if (weatherInfo.bulletin.marqueewarnings.length != 0){
if (weatherInfo.bulletin.marqueewarnings[0].significance == "Y" ||weatherInfo.bulletin.marqueewarnings[0].significance == "S") {

View File

@ -523,7 +523,7 @@ function grabCitySlidesData() {
//get only weather alers
for (ai=0; ai<=ajaxedLoc["v3alertsHeadlines"].alerts.length - 1; ai++) {
warning = ajaxedLoc["v3alertsHeadlines"].alerts[ai].categories[0].category;
if ((warning == "Met" && weatherInfo.bulletin.includesevereonbulletin == true) || (warning == "Met" && ajaxedLoc["v3alertsHeadlines"].alerts[ai].eventDescription != "Severe Thunderstorm Warning" && ajaxedLoc["v3alertsHeadlines"].alerts[ai].eventDescription == "Flash Flood Warning" != ajaxedLoc["v3alertsHeadlines"].alerts[ai].eventDescription != "Tornado Warning")) {
if ((warning == "Met" && weatherInfo.bulletin.includesevereonbulletin == true) || (warning == "Met" && i != 0) || (warning == "Met" && ajaxedLoc["v3alertsHeadlines"].alerts[ai].eventDescription != "Severe Thunderstorm Warning" && ajaxedLoc["v3alertsHeadlines"].alerts[ai].eventDescription == "Flash Flood Warning" != ajaxedLoc["v3alertsHeadlines"].alerts[ai].eventDescription != "Tornado Warning")) {
ret.push({idx:ai, priority: getWarningPosition(ajaxedLoc["v3alertsHeadlines"].alerts[ai].eventDescription)})
}
};