aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/com/juick
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/com/juick')
-rw-r--r--src/main/java/com/juick/server/api/ApiSocialLogin.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/main/java/com/juick/server/api/ApiSocialLogin.java b/src/main/java/com/juick/server/api/ApiSocialLogin.java
index c24d1618..164c71a4 100644
--- a/src/main/java/com/juick/server/api/ApiSocialLogin.java
+++ b/src/main/java/com/juick/server/api/ApiSocialLogin.java
@@ -190,6 +190,7 @@ public class ApiSocialLogin {
}
UriComponentsBuilder uriComponentsBuilder = UriComponentsBuilder.fromUriString(redirectUrl);
uriComponentsBuilder.queryParam("hash", userService.getHashByUID(uid));
+ uriComponentsBuilder.queryParam("retpath", redirectUrl);
return "redirect:" + uriComponentsBuilder.build().toUriString();
} else {
if (!crosspostService.createFacebookUser(fbID, state, token.getAccessToken(), fb.getName())) {
@@ -240,6 +241,7 @@ public class ApiSocialLogin {
if (uid > 0) {
UriComponentsBuilder uriComponentsBuilder = UriComponentsBuilder.fromUriString(redirectUrl);
uriComponentsBuilder.queryParam("hash", userService.getHashByUID(uid));
+ uriComponentsBuilder.queryParam("retpath", redirectUrl);
return "redirect:" + uriComponentsBuilder.build().toUriString();
} else {
String loginhash = UUID.randomUUID().toString();
@@ -341,6 +343,7 @@ public class ApiSocialLogin {
}
UriComponentsBuilder uriComponentsBuilder = UriComponentsBuilder.fromUriString(redirectUrl);
uriComponentsBuilder.queryParam("hash", userService.getHashByUID(user.getUid()));
+ uriComponentsBuilder.queryParam("retpath", redirectUrl);
return "redirect:" + uriComponentsBuilder.build().toUriString();
} else {
String verificationCode = RandomStringUtils.randomAlphanumeric(8).toUpperCase();