Skip to content

Commit 8956d2f

Browse files
committed
formatting
1 parent 0a0c09c commit 8956d2f

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

src/input.rs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -141,13 +141,9 @@ pub fn is_key_repeated(key_code: KeyCode) -> bool {
141141
// stores the amount of time each key has been pressed for
142142
let time_map = &mut context.keys_repeated;
143143

144-
time_map
145-
.entry(key_code)
146-
.or_insert(0.);
144+
time_map.entry(key_code).or_insert(0.);
147145

148-
let time_pressed = time_map
149-
.get_mut(&key_code)
150-
.unwrap();
146+
let time_pressed = time_map.get_mut(&key_code).unwrap();
151147

152148
if is_key_down(key_code) {
153149
*time_pressed += 1.;

0 commit comments

Comments
 (0)