mirror of
https://github.com/qvacua/vimr.git
synced 2024-11-28 11:35:35 +03:00
GH-220 Set feed url correctly
This commit is contained in:
parent
992f15096a
commit
237e4a9ddd
@ -68,10 +68,20 @@ class PrefStore: StandardFlow {
|
||||
self.userDefaults.setValue(self.prefsDict(self.data), forKey: PrefStore.compatibleVersion)
|
||||
}
|
||||
|
||||
if self.data.advanced.useSnapshotUpdateChannel {
|
||||
SUUpdater.shared().feedURL = URL(
|
||||
string: "https://raw.githubusercontent.com/qvacua/vimr/master/appcast_snapshot.xml"
|
||||
)
|
||||
self.setSparkleUrl()
|
||||
}
|
||||
|
||||
fileprivate func setSparkleUrl() {
|
||||
DispatchUtils.gui {
|
||||
if self.data.advanced.useSnapshotUpdateChannel {
|
||||
SUUpdater.shared().feedURL = URL(
|
||||
string: "https://raw.githubusercontent.com/qvacua/vimr/master/appcast_snapshot.xml"
|
||||
)
|
||||
} else {
|
||||
SUUpdater.shared().feedURL = URL(
|
||||
string: "https://raw.githubusercontent.com/qvacua/vimr/master/appcast.xml"
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -180,6 +190,7 @@ class PrefStore: StandardFlow {
|
||||
}
|
||||
|
||||
self.userDefaults.setValue(self.prefsDict(self.data), forKey: PrefStore.compatibleVersion)
|
||||
self.setSparkleUrl()
|
||||
self.publish(event: self.data)
|
||||
})
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user