chore: fix check enable signup

This commit is contained in:
Steven 2023-09-24 23:46:28 +08:00
parent fc8808ce04
commit 60c440ae10
3 changed files with 3 additions and 2 deletions

View File

@ -4,6 +4,7 @@ import "strings"
var allowedMethodsWhenUnauthorized = map[string]bool{ var allowedMethodsWhenUnauthorized = map[string]bool{
"/slash.api.v2.WorkspaceService/GetWorkspaceProfile": true, "/slash.api.v2.WorkspaceService/GetWorkspaceProfile": true,
"/slash.api.v2.WorkspaceService/GetWorkspaceSetting": true,
} }
// isUnauthorizeAllowedMethod returns true if the method is allowed to be called when the user is not authorized. // isUnauthorizeAllowedMethod returns true if the method is allowed to be called when the user is not authorized.

View File

@ -104,7 +104,7 @@ const SignIn: React.FC = () => {
</Button> </Button>
</div> </div>
</form> </form>
{workspaceStore.setting.enableSignup && ( {workspaceStore.profile.enableSignup && (
<p className="w-full mt-4 text-sm"> <p className="w-full mt-4 text-sm">
<span className="dark:text-gray-500">{"Don't have an account yet?"}</span> <span className="dark:text-gray-500">{"Don't have an account yet?"}</span>
<Link to="/auth/signup" className="cursor-pointer ml-2 text-blue-600 hover:underline"> <Link to="/auth/signup" className="cursor-pointer ml-2 text-blue-600 hover:underline">

View File

@ -27,7 +27,7 @@ const SignUp: React.FC = () => {
}); });
} }
if (!workspaceStore.setting.enableSignup) { if (!workspaceStore.profile.enableSignup) {
return navigateTo("/auth", { return navigateTo("/auth", {
replace: true, replace: true,
}); });