fix derive file style in constructor
This commit is contained in:
parent
72b0b5a706
commit
ca51e1d788
1 changed files with 15 additions and 16 deletions
|
@ -133,7 +133,7 @@ export class GPXFile extends GPXTreeNode<Track> {
|
||||||
}
|
}
|
||||||
if (gpx.hasOwnProperty('_data')) {
|
if (gpx.hasOwnProperty('_data')) {
|
||||||
this._data = gpx._data;
|
this._data = gpx._data;
|
||||||
|
}
|
||||||
if (!this._data.hasOwnProperty('style')) {
|
if (!this._data.hasOwnProperty('style')) {
|
||||||
let style = this.getStyle();
|
let style = this.getStyle();
|
||||||
let fileStyle = {};
|
let fileStyle = {};
|
||||||
|
@ -150,7 +150,6 @@ export class GPXFile extends GPXTreeNode<Track> {
|
||||||
this.setStyle(fileStyle);
|
this.setStyle(fileStyle);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
this.attributes = {};
|
this.attributes = {};
|
||||||
this.metadata = {};
|
this.metadata = {};
|
||||||
|
|
Loading…
Reference in a new issue