From 43f3057c8e9684f92ad1f1c4a7d6056ac9ac4343 Mon Sep 17 00:00:00 2001 From: Jake Meyer Date: Sat, 12 Jan 2019 14:17:36 -0600 Subject: [PATCH] remove Iridium NEXT fixes for upcoming launch script --- README.md | 2 +- scripts/upcoming.js | 18 ++---------------- 2 files changed, 3 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index 2f83a5ce..b7edb3d0 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -

+

SpaceX REST API

diff --git a/scripts/upcoming.js b/scripts/upcoming.js index d1937421..a10e138f 100644 --- a/scripts/upcoming.js +++ b/scripts/upcoming.js @@ -64,15 +64,7 @@ const month_vague = /^[0-9]{4}\s(early|mid|late)\s([a-z]{3}|[a-z]{3,9})$/i; // Collect site names for time zone and payload name for fuzzy check launches.forEach(launch => { - // Add temp fix for last Iridium NEXT launch because we need fuzzy - // search to return 100% substring match, else we get SSO-A and SSO-B changing - // because of a slight difference. - // NOTE: Will be removed after launch - if (launch.rocket.second_stage.payloads[0].payload_id === 'Iridium NEXT 8') { - payloads.push('Iridium 8'); - } else { - payloads.push(launch.rocket.second_stage.payloads[0].payload_id); - } + payloads.push(launch.rocket.second_stage.payloads[0].payload_id); sites.push(launch.launch_site.site_id); }); @@ -84,7 +76,7 @@ const month_vague = /^[0-9]{4}\s(early|mid|late)\s([a-z]{3}|[a-z]{3,9})$/i; const manifest = $('body > div.content > div > div > table:nth-child(6) > tbody').text(); const manifest_row = manifest.split('\n').filter(v => v !== ''); - // Filter to collect manaifest dates + // Filter to collect manifest dates const manifest_dates = manifest_row.filter((value, index) => index % 8 === 0); // Filter to collect payload names @@ -233,12 +225,6 @@ const month_vague = /^[0-9]{4}\s(early|mid|late)\s([a-z]{3}|[a-z]{3,9})$/i; console.log(calculatedTimes); console.log(''); - // Another special case added for last Iridium launch - // NOTE: Will be removed after launch - if (payload === 'Iridium 8') { - payload = 'Iridium NEXT 8'; - } - // Add to array of promises to update all at once after the forEach iterations finish promises.push(col.updateOne({ 'rocket.second_stage.payloads.payload_id': payload }, { $set: calculatedTimes })); }