From 4f6a53b7cf8e2ffed654ab0e11a5536fe9397aa0 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Wed, 23 Sep 2020 13:52:59 -0500 Subject: [PATCH] Switching to iterator. --- src/api/mod.rs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/api/mod.rs b/src/api/mod.rs index 53b805268..785bd601e 100644 --- a/src/api/mod.rs +++ b/src/api/mod.rs @@ -107,11 +107,12 @@ pub(in crate::api) async fn linked_instances(pool: &DbPool) -> Result, LemmyError>>()?; - instances.extend(Settings::get().get_allowed_instances().into_iter()); + instances.append(&mut Settings::get().get_allowed_instances()); instances.retain(|a| { !Settings::get().get_blocked_instances().contains(a) && !a.eq("")