diff options
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/main.rs b/src/main.rs index 7e00368..d03f88a 100644 --- a/src/main.rs +++ b/src/main.rs | |||
@@ -170,10 +170,10 @@ async fn main() { | |||
170 | lock, | 170 | lock, |
171 | } => { | 171 | } => { |
172 | let listf = match list { | 172 | let listf = match list { |
173 | Some(list) => lists_get(&config, list).unwrap(), | 173 | Some(list) => lists_get(&config, &list).unwrap(), |
174 | None => lists_get( | 174 | None => lists_get( |
175 | &config, | 175 | &config, |
176 | config_get_current_list(&config).unwrap(), | 176 | &config_get_current_list(&config).unwrap(), |
177 | ) | 177 | ) |
178 | .unwrap(), | 178 | .unwrap(), |
179 | }; | 179 | }; |
@@ -189,10 +189,10 @@ async fn main() { | |||
189 | } | 189 | } |
190 | ModCommands::Remove { id, list } => { | 190 | ModCommands::Remove { id, list } => { |
191 | let listf = match list { | 191 | let listf = match list { |
192 | Some(list) => lists_get(&config, list).unwrap(), | 192 | Some(list) => lists_get(&config, &list).unwrap(), |
193 | None => lists_get( | 193 | None => lists_get( |
194 | &config, | 194 | &config, |
195 | config_get_current_list(&config).unwrap(), | 195 | &config_get_current_list(&config).unwrap(), |
196 | ) | 196 | ) |
197 | .unwrap(), | 197 | .unwrap(), |
198 | }; | 198 | }; |
@@ -231,7 +231,7 @@ async fn main() { | |||
231 | version, | 231 | version, |
232 | download, | 232 | download, |
233 | remove, | 233 | remove, |
234 | } => list_version(&config, id, version, download, remove).await, | 234 | } => list_version(&config, &id, version, download, remove).await, |
235 | } | 235 | } |
236 | } | 236 | } |
237 | Commands::Update { | 237 | Commands::Update { |
@@ -245,11 +245,11 @@ async fn main() { | |||
245 | if all { | 245 | if all { |
246 | let list_ids = lists_get_all_ids(&config).unwrap(); | 246 | let list_ids = lists_get_all_ids(&config).unwrap(); |
247 | for id in list_ids { | 247 | for id in list_ids { |
248 | liststack.push(lists_get(&config, id).unwrap()); | 248 | liststack.push(lists_get(&config, &id).unwrap()); |
249 | } | 249 | } |
250 | } else { | 250 | } else { |
251 | let current = match list { | 251 | let current = match list { |
252 | Some(l) => lists_get(&config, l).unwrap(), | 252 | Some(l) => lists_get(&config, &l).unwrap(), |
253 | None => get_current_list(&config).unwrap(), | 253 | None => get_current_list(&config).unwrap(), |
254 | }; | 254 | }; |
255 | liststack.push(current) | 255 | liststack.push(current) |
@@ -262,11 +262,11 @@ async fn main() { | |||
262 | if all { | 262 | if all { |
263 | let list_ids = lists_get_all_ids(&config).unwrap(); | 263 | let list_ids = lists_get_all_ids(&config).unwrap(); |
264 | for id in list_ids { | 264 | for id in list_ids { |
265 | liststack.push(lists_get(&config, id).unwrap()); | 265 | liststack.push(lists_get(&config, &id).unwrap()); |
266 | } | 266 | } |
267 | } else { | 267 | } else { |
268 | let current = match list { | 268 | let current = match list { |
269 | Some(l) => lists_get(&config, l).unwrap(), | 269 | Some(l) => lists_get(&config, &l).unwrap(), |
270 | None => get_current_list(&config).unwrap(), | 270 | None => get_current_list(&config).unwrap(), |
271 | }; | 271 | }; |
272 | liststack.push(current) | 272 | liststack.push(current) |
@@ -285,7 +285,7 @@ async fn main() { | |||
285 | .unwrap(), | 285 | .unwrap(), |
286 | }; | 286 | }; |
287 | 287 | ||
288 | import(&config, filestr, download).await | 288 | import(&config, &filestr, download).await |
289 | } | 289 | } |
290 | Commands::Export { list } => export(&config, list), | 290 | Commands::Export { list } => export(&config, list), |
291 | Commands::Test => Ok(()), | 291 | Commands::Test => Ok(()), |