From: Sander Saarend <sander@saarend.com>
Date: Wed, 19 Jul 2023 15:04:43 +0000 (+0300)
Subject: Use local_site.default_post_listing_type as the initial default listing type for... 
X-Git-Url: http://these/git/%7B%60/feeds/%7B%60%24%7BwebArchiveUrl%7D/save/static/git-logo.png?a=commitdiff_plain;h=d7051c40f81ee7d283dc3fd14144922e392a7781;p=lemmy.git

Use local_site.default_post_listing_type as the initial default listing type for new users (#3666)
---

diff --git a/crates/api_crud/src/user/create.rs b/crates/api_crud/src/user/create.rs
index c2f42bba..caba9bd8 100644
--- a/crates/api_crud/src/user/create.rs
+++ b/crates/api_crud/src/user/create.rs
@@ -138,6 +138,7 @@ impl PerformCrud for Register {
       .password_encrypted(data.password.to_string())
       .show_nsfw(Some(data.show_nsfw))
       .accepted_application(accepted_application)
+      .default_listing_type(Some(local_site.default_post_listing_type))
       .build();
 
     let inserted_local_user = LocalUser::create(&mut context.pool(), &local_user_form).await?;