Skip to content

Commit a1c93c9

Browse files
committed
Update GPXRoot.swift
1 parent e89ff32 commit a1c93c9

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Classes/GPXRoot.swift

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import Foundation
1515
open class GPXRoot: GPXElement {
1616

1717
/// GPX version that will be generated. Currently, only the latest (version 1.1) is supported.
18-
public var version: String? = "1.1"
18+
public var version: String?
1919

2020
/// Name of the creator of the GPX content.
2121
///
@@ -60,7 +60,8 @@ open class GPXRoot: GPXElement {
6060
///
6161
public required init() {
6262
super.init()
63-
creator = "Powered by Open Source CoreGPX Project"
63+
self.creator = "Powered by Open Source CoreGPX Project"
64+
self.version = "1.1"
6465
}
6566

6667
/// for initializing with a creator name
@@ -71,6 +72,7 @@ open class GPXRoot: GPXElement {
7172
public init(creator: String) {
7273
super.init()
7374
self.creator = creator
75+
self.version = "1.1"
7476
}
7577

7678
internal init(dictionary: [String : String]) {

0 commit comments

Comments
 (0)