Skip to content

Commit

Permalink
fix: 🐛 fix missing name property on GroundObjects
Browse files Browse the repository at this point in the history
  • Loading branch information
thkruz committed Jan 19, 2024
1 parent d360ce8 commit cba039d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/objects/GroundObject.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ import { BaseObject } from './BaseObject';
import { Satellite } from './Satellite';

export class GroundObject extends BaseObject {
name = 'Unknown Ground Position';
name = 'Unknown Ground Object';
lat: Degrees;
lon: Degrees;
alt: Kilometers;
Expand All @@ -52,6 +52,7 @@ export class GroundObject extends BaseObject {
super(info);

this.validateGroundObjectInputData_(info);
this.name = info.name ?? this.name;
this.lat = info.lat;
this.lon = info.lon;
this.alt = info.alt;
Expand Down
2 changes: 1 addition & 1 deletion test/objects/__snapshots__/GroundObject.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ GroundObject {
"id": undefined,
"lat": 0,
"lon": 0,
"name": "Unknown Ground Position",
"name": "Unknown Ground Object",
"position": Object {
"x": 0,
"y": 0,
Expand Down

0 comments on commit cba039d

Please sign in to comment.