From 87e79817f7cde700d992685e8d0a8b209da78147 Mon Sep 17 00:00:00 2001 From: James Date: Fri, 31 Jul 2020 12:12:36 -0400 Subject: [PATCH] fixes errors with client registration process --- src/client/components/views/collections/Edit/Auth/index.js | 2 +- src/client/components/views/collections/Edit/index.js | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/client/components/views/collections/Edit/Auth/index.js b/src/client/components/views/collections/Edit/Auth/index.js index c44897f0c8..7cebcaccec 100644 --- a/src/client/components/views/collections/Edit/Auth/index.js +++ b/src/client/components/views/collections/Edit/Auth/index.js @@ -34,7 +34,7 @@ const Auth = (props) => { label="Email" autoComplete="email" /> - {changingPassword && ( + {(changingPassword || requirePassword) && (
{ const collectionPermissions = permissions?.[slug]; const apiURL = `${serverURL}${api}/${slug}/${id}`; - let action = `${serverURL}${api}/${slug}${isEditing ? `/${id}` : ''}?depth=0`; + let action = `${serverURL}${api}/${slug}${isEditing ? `/${id}` : ''}`; const hasSavePermission = (isEditing && collectionPermissions?.update?.permission) || (!isEditing && collectionPermissions?.create?.permission); if (auth && !isEditing) { action = `${action}/register`; } + action += '?depth=0'; + return (