Skip to content

Commit 4853abd

Browse files
author
Deren Vural
committed
added explicit type to settings in main impl
Signed-off-by: Deren Vural <[email protected]>
1 parent 6567e56 commit 4853abd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/settingswindow/imp.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ impl SettingsWindow {
8585
let new_value: i32 = button.value_as_int();
8686

8787
// Set refresh rate property
88-
let settings = self.settings.get().expect("..Cannot retrieve settings");
88+
let settings: &Settings = self.settings.get().expect("..Cannot retrieve settings");
8989
settings
9090
.set_int("refreshrate", new_value)
9191
.expect("..Cannot set `tempformat` setting");
@@ -110,14 +110,14 @@ impl SettingsWindow {
110110
match unit.as_str() {
111111
"Celcius (C)" => {
112112
// Set temperature unit as C
113-
let settings = self.settings.get().expect("..Cannot retrieve settings");
113+
let settings: &Settings = self.settings.get().expect("..Cannot retrieve settings");
114114
settings
115115
.set_int("tempformat", 0)
116116
.expect("..Cannot set `tempformat` setting");
117117
}
118118
"Fahrenheit (F)" => {
119119
// Set temperature unit as F
120-
let settings = self.settings.get().expect("..Cannot retrieve settings");
120+
let settings: &Settings = self.settings.get().expect("..Cannot retrieve settings");
121121
settings
122122
.set_int("tempformat", 1)
123123
.expect("..Cannot set `tempformat` setting");

0 commit comments

Comments
 (0)