Skip to content

Commit

Permalink
Added env template
Browse files Browse the repository at this point in the history
  • Loading branch information
jacoblurie29 committed Jan 14, 2024
1 parent 33e26e4 commit 4b1bd8a
Show file tree
Hide file tree
Showing 3 changed files with 79 additions and 75 deletions.
4 changes: 4 additions & 0 deletions .env.template
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
ENVIRONMENT=
HOST=
PORT=
AIRTABLE_API_KEY=
8 changes: 4 additions & 4 deletions build/controllers/TestControllers/retrievePassengers.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.retrievePassengers = void 0;
/* eslint-disable autofix/no-unused-vars */
/* eslint-disable @typescript-eslint/no-unused-vars */
const airtable_1 = __importDefault(require("airtable"));
const dotenv_1 = __importDefault(require("dotenv"));
dotenv_1.default.config();
Expand All @@ -23,7 +21,7 @@ dotenv_1.default.config();
const retrievePassengers = (req, res) => __awaiter(void 0, void 0, void 0, function* () {
console.log(process.env.AIRTABLE_API_KEY);
const base = new airtable_1.default({
apiKey: process.env.AIRTABLE_API_KEY || "",
apiKey: process.env.AIRTABLE_API_KEY || '',
}).base('appwPsfAb6U8CV3mf');
base('Flight Requests (Trips)')
.select({
Expand All @@ -38,7 +36,9 @@ const retrievePassengers = (req, res) => __awaiter(void 0, void 0, void 0, funct
return;
}
if (records) {
const flightLegs = records.map(record => record.fields["Flight Legs"] !== undefined ? record.fields["Flight Legs"] : []);
const flightLegs = records.map(record => record.fields['Flight Legs'] !== undefined
? record.fields['Flight Legs']
: []);
console.log('Retrieved Flight Leg IDs', flightLegs);
try {
const trips = [];
Expand Down
142 changes: 71 additions & 71 deletions build/data/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,75 +2,75 @@
Object.defineProperty(exports, "__esModule", { value: true });
exports.AIRLINES = void 0;
exports.AIRLINES = [
"AA - American Airlines",
"AC - Air Canada",
"AE - American Eagle",
"AF - Air France",
"AG - Allegiant",
"AI - Air India",
"AK - Alaska",
"AL - Aer Lingus",
"AM - AeroMexico",
"AN - Air New Zealand",
"AO - Aeroflot",
"AR - Air Transat",
"AS - Air Serbia",
"AT - AirTran",
"ATA - American Trans Air",
"AU - Austrian Airlines",
"AV - Avianca",
"AW - America West",
"BA - British Airways",
"BH - Bahamasair",
"BS - Big Sky",
"CA - Corporate Airlines",
"CM - Com-Air",
"CN - Canadian Airlines",
"CO - Continental",
"CP - Copa Airlines",
"DA - Domodedovo Airlines",
"DL - Delta",
"EJ - Express Jet",
"EK - Emirates",
"FT - Frontier",
"GA - Grenadine Air Alliance",
"GL - Great Lakes",
"HA - Horizon Airlines",
"HI - Hawaiian Airlines",
"IA - Island Air",
"IC - Iceland Air",
"JB - JetBlue Airways",
"KLM - KLM Royal Dutch Airlines",
"LH - Lufhansa",
"LT - Liat Airlines",
"ME - Midway",
"MS - Mesaba",
"MU - Mustique Airways",
"MW - Midwest",
"MX - Mexicana",
"NA - National",
"NW - Northwest",
"OC - One Caribbean",
"QA - Qantas",
"RA - Ravn Alaska",
"SA - South African",
"SC - SunCountry",
"SK - Skywest",
"SM - Skyway",
"SN - Scandinavian",
"SP - Spirit",
"SVG - SVG Air",
"SW - Southwest",
"TA - Tropic Air",
"TK - Turkish Airlines",
"TWA - TransWorld Air",
"UN - United",
"US - US Airways",
"VA - Vanguard",
"VG - Virgin America",
"VL - Volaris Airlines",
"WJ - West Jet",
"US - US Aiways",
"SAE - Southern Airways Express",
"Qatar Airways",
'AA - American Airlines',
'AC - Air Canada',
'AE - American Eagle',
'AF - Air France',
'AG - Allegiant',
'AI - Air India',
'AK - Alaska',
'AL - Aer Lingus',
'AM - AeroMexico',
'AN - Air New Zealand',
'AO - Aeroflot',
'AR - Air Transat',
'AS - Air Serbia',
'AT - AirTran',
'ATA - American Trans Air',
'AU - Austrian Airlines',
'AV - Avianca',
'AW - America West',
'BA - British Airways',
'BH - Bahamasair',
'BS - Big Sky',
'CA - Corporate Airlines',
'CM - Com-Air',
'CN - Canadian Airlines',
'CO - Continental',
'CP - Copa Airlines',
'DA - Domodedovo Airlines',
'DL - Delta',
'EJ - Express Jet',
'EK - Emirates',
'FT - Frontier',
'GA - Grenadine Air Alliance',
'GL - Great Lakes',
'HA - Horizon Airlines',
'HI - Hawaiian Airlines',
'IA - Island Air',
'IC - Iceland Air',
'JB - JetBlue Airways',
'KLM - KLM Royal Dutch Airlines',
'LH - Lufhansa',
'LT - Liat Airlines',
'ME - Midway',
'MS - Mesaba',
'MU - Mustique Airways',
'MW - Midwest',
'MX - Mexicana',
'NA - National',
'NW - Northwest',
'OC - One Caribbean',
'QA - Qantas',
'RA - Ravn Alaska',
'SA - South African',
'SC - SunCountry',
'SK - Skywest',
'SM - Skyway',
'SN - Scandinavian',
'SP - Spirit',
'SVG - SVG Air',
'SW - Southwest',
'TA - Tropic Air',
'TK - Turkish Airlines',
'TWA - TransWorld Air',
'UN - United',
'US - US Airways',
'VA - Vanguard',
'VG - Virgin America',
'VL - Volaris Airlines',
'WJ - West Jet',
'US - US Aiways',
'SAE - Southern Airways Express',
'Qatar Airways',
];

0 comments on commit 4b1bd8a

Please sign in to comment.