1
0
mirror of https://github.com/gilbertchen/duplicacy synced 2025-12-13 14:53:28 +00:00

FindPreference should return the address of the Preference object for setPreference to work

This commit is contained in:
Gilbert Chen
2017-08-24 23:02:39 -04:00
parent fd362be54a
commit 8fce6f5f83

View File

@@ -108,9 +108,9 @@ func SavePreferences() (bool) {
}
func FindPreference(name string) (*Preference) {
for _, preference := range Preferences {
for i, preference := range Preferences {
if preference.Name == name || preference.StorageURL == name {
return &preference
return &Preferences[i]
}
}