From fe96581ca957a1e73b3c9cd8b4c36f15cd0e1e9f Mon Sep 17 00:00:00 2001 From: Neeraj Gupta <254676+ua741@users.noreply.github.com> Date: Thu, 3 Mar 2022 22:00:09 +0530 Subject: [PATCH] Fix bug in validating password length --- src/components/CollectionShare.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/CollectionShare.tsx b/src/components/CollectionShare.tsx index 890eb21c2..0868ea766 100644 --- a/src/components/CollectionShare.tsx +++ b/src/components/CollectionShare.tsx @@ -210,7 +210,7 @@ function CollectionShare(props: Props) { { linkPassword }: passFormValues, { setFieldError }: FormikHelpers ) => { - if (linkPassword && linkPassword.length > 1) { + if (linkPassword && linkPassword.trim().length >= 1) { setConfigurePassword(!configurePassword); await enablePublicUrlPassword(linkPassword); } else {