mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-11-28 16:37:44 +00:00
Update create.rs
This commit is contained in:
parent
00eed9d3c8
commit
f456122ecb
|
@ -6,7 +6,6 @@ use lemmy_api_common::{
|
|||
person::{LoginResponse, Register},
|
||||
utils::{
|
||||
generate_inbox_url,
|
||||
generate_local_apub_endpoint,
|
||||
generate_shared_inbox_url,
|
||||
honeypot_check,
|
||||
local_site_to_slur_regex,
|
||||
|
@ -97,11 +96,6 @@ pub async fn register(
|
|||
|
||||
let actor_keypair = generate_actor_keypair()?;
|
||||
is_valid_actor_name(&data.username, local_site.actor_name_max_length as usize)?;
|
||||
let actor_id = generate_local_apub_endpoint(
|
||||
EndpointType::Person,
|
||||
&data.username,
|
||||
&context.settings().get_protocol_and_hostname(),
|
||||
)?;
|
||||
|
||||
if let Some(email) = &data.email {
|
||||
if LocalUser::is_email_taken(&mut context.pool(), email).await? {
|
||||
|
@ -113,7 +107,6 @@ pub async fn register(
|
|||
|
||||
// Register the new person
|
||||
let person_form = PersonInsertForm {
|
||||
actor_id: Some(actor_id.clone()),
|
||||
inbox_url: Some(generate_inbox_url(&actor_id)?),
|
||||
shared_inbox_url: Some(generate_shared_inbox_url(context.settings())?),
|
||||
private_key: Some(actor_keypair.private_key),
|
||||
|
|
Loading…
Reference in a new issue