Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions debug.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,9 +112,9 @@ async function performCommand(command) {
break;
case 'vehicles':
const vehicles = await client.getVehicles();
const response = vehicles.map(v => {
const { name, vin, nickname, regDate } = v.vehicleConfig;
return { name, vin, nickname, regDate };
const response = vehicles.map(v => {
const { name, vin, nickname, regDate, generation } = v.vehicleConfig;
return { name, vin, nickname, regDate, generation};
});
console.log('vehicles', JSON.stringify(response, null, 2));
break;
Expand Down
2 changes: 0 additions & 2 deletions src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ export const ALL_ENDPOINTS = {
getAUBrandEnvironment({ brand }).endpoints,
};

export const GEN2 = 2;
export const GEN1 = 1;
export type REGION = 'US' | 'CA' | 'EU' | 'CN' | 'AU';
export enum REGIONS {
US = 'US',
Expand Down
2 changes: 1 addition & 1 deletion src/controllers/american.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ export class AmericanController extends SessionController<AmericanBlueLinkyConfi
regDate: vehicleInfo.enrollmentDate,
brandIndicator: vehicleInfo.brandIndicator,
regId: vehicleInfo.regid,
generation: vehicleInfo.modelYear > 2016 ? '2' : '1',
generation: vehicleInfo.vehicleGeneration,
} as VehicleRegisterOptions;
return new AmericanVehicle(vehicleConfig, this);
});
Expand Down