[BUG] Fix #210 Duplicating KCPTUN enabled profiles does not copy KCPTUN related settings
This commit is contained in:
@ -9,7 +9,7 @@
|
|||||||
import Foundation
|
import Foundation
|
||||||
|
|
||||||
|
|
||||||
class KcptunProfile: NSObject {
|
class KcptunProfile: NSObject, NSCopying {
|
||||||
|
|
||||||
var mode: String = "fast"
|
var mode: String = "fast"
|
||||||
|
|
||||||
@ -29,6 +29,7 @@ class KcptunProfile: NSObject {
|
|||||||
copy.nocomp = self.nocomp
|
copy.nocomp = self.nocomp
|
||||||
copy.datashard = self.datashard
|
copy.datashard = self.datashard
|
||||||
copy.parityshard = self.parityshard
|
copy.parityshard = self.parityshard
|
||||||
|
copy.mtu = self.mtu
|
||||||
return copy;
|
return copy;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -101,6 +101,9 @@ class ServerProfile: NSObject, NSCopying {
|
|||||||
copy.password = self.password
|
copy.password = self.password
|
||||||
copy.remark = self.remark
|
copy.remark = self.remark
|
||||||
copy.ota = self.ota
|
copy.ota = self.ota
|
||||||
|
|
||||||
|
copy.enabledKcptun = self.enabledKcptun
|
||||||
|
copy.kcptunProfile = self.kcptunProfile.copy() as! KcptunProfile
|
||||||
return copy;
|
return copy;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user