Skip to content

Commit 4df8b9f

Browse files
authored
Merge pull request #3712 from SkymindIO/sl/nosignup_prod
Disable sign-ups on prod
2 parents 957e337 + 57eb492 commit 4df8b9f

File tree

3 files changed

+14
-9
lines changed

3 files changed

+14
-9
lines changed

pathmind-webapp/src/main/java/io/skymind/pathmind/webapp/ui/views/account/AccountUpgradeView.java

+5-3
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,11 @@ public AccountUpgradeView(AccountUpgradeViewContent accountUpgradeViewContent,
2828
@Override
2929
public void beforeEnter(BeforeEnterEvent event) {
3030
// if user has an ongoing subscription this view shouldn't be shown
31-
if (!featureManager.isEnabled(Feature.ACCOUNT_UPGRADE)) {
32-
event.rerouteTo(AccountView.class);
33-
}
31+
32+
// reroute all users - slin
33+
// if (!featureManager.isEnabled(Feature.ACCOUNT_UPGRADE)) {
34+
event.rerouteTo(AccountView.class);
35+
// }
3436

3537
super.beforeEnter(event);
3638
}

pathmind-webapp/src/main/java/io/skymind/pathmind/webapp/ui/views/login/LoginView.java

+7-6
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,9 @@ public LoginView(@Value("${pathmind.privacy-policy.url}") String privacyPolicyUr
9191
Div innerContent = new Div();
9292
innerContent.setClassName("inner-content");
9393
// Allow new users to sign up for free trials: https://github.com/SkymindIO/pathmind-webapp/issues/2199
94-
innerContent.add(title, badCredentials, emailNotVerified, sessionExpired, createLoginForm(), createSignUp());
95-
// innerContent.add(title, badCredentials, emailNotVerified, sessionExpired, createLoginForm());
94+
// innerContent.add(title, badCredentials, emailNotVerified, sessionExpired, createLoginForm(), createSignUp());
95+
// Removing links to sign up page
96+
innerContent.add(title, badCredentials, emailNotVerified, sessionExpired, createLoginForm());
9697

9798
Anchor termsLink = new Anchor(termsOfUseUrl, "Terms of Use");
9899
termsLink.setTarget("_blank");
@@ -174,10 +175,10 @@ public void beforeEnter(BeforeEnterEvent event) {
174175
event.forwardTo(ProjectsView.class);
175176
return;
176177
}
177-
if (CookieUtils.getCookie("isFirstTimeVisit") == null) {
178-
CookieUtils.setNotFirstTimeVisitCookie();
179-
event.forwardTo(SignUpView.class);
180-
}
178+
// if (CookieUtils.getCookie("isFirstTimeVisit") == null) {
179+
// CookieUtils.setNotFirstTimeVisitCookie();
180+
// event.forwardTo(SignUpView.class);
181+
// }
181182
add(segmentIntegrator);
182183
}
183184

pathmind-webapp/src/main/java/io/skymind/pathmind/webapp/ui/views/login/SignUpView.java

+2
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,8 @@ private void processValidationStatusChange(boolean hasValidationErrors) {
145145

146146
@Override
147147
public void setParameter(BeforeEvent event, @OptionalParameter String parameter) {
148+
// send all users away from sign-up
149+
event.forwardTo(LoginView.class);
148150
Location location = event.getLocation();
149151
QueryParameters queryParameters = location.getQueryParameters();
150152

0 commit comments

Comments
 (0)