Skip to content

Commit 48cc29d

Browse files
committed
Fix badge schema
1 parent 73b4533 commit 48cc29d

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

RCCService/AppSettings.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
<Settings>
33
<ContentFolder>content</ContentFolder>
44
<BaseUrl>http://bbblox.org</BaseUrl>
5-
</Settings>
5+
</Settings>

Roblox/Roblox.Website/Controllers/Internal/Other/Login.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@ private static string HashString(string input)
160160
Response.Cookies.Delete("signupkey");
161161
Response.Cookies.Delete("resetpasstoken");
162162
Response.Cookies.Delete("resetpasswordverified");
163+
Response.Cookies.Delete("2FACode");
163164

164165
HttpContext.Response.Cookies.Append(
165166
".ROBLOSECURITY",
@@ -231,14 +232,14 @@ public async Task<IActionResult> TwoFactorLogin([FromForm] string code)
231232
{
232233
if (!Temp2FATokens.TryGetValue(token, out userId))
233234
{
234-
return Redirect("/login/2fa?err=Invalid+or+expired+2FA+token,+please+try+logging+in+again!");
235+
return Redirect("/");
235236
}
236237
}
237238

238239
bool Valid = await services.twoFactor.VerifyCode(userId, code);
239240
if (!Valid)
240241
{
241-
return Redirect("/login/2fa?err=Bad+or+expired+2FA+code,+please+try+again!");
242+
return Redirect("/login/2fa?err=Bad/expired+2FA+code,+please+try+again!");
242243
}
243244

244245
lock (Temp2FALock)
@@ -1040,6 +1041,7 @@ await db.ExecuteAsync(
10401041
Response.Cookies.Delete("signupkey");
10411042
Response.Cookies.Delete("resetpasstoken");
10421043
Response.Cookies.Delete("resetpasswordverified");
1044+
Response.Cookies.Delete("2FACode");
10431045

10441046
return Redirect("/home");
10451047
}

api/sql/schema.sql

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -372,12 +372,13 @@ ALTER TABLE public.asset_place OWNER TO postgres;
372372
CREATE TABLE public.asset_place_badge (
373373
badge_id bigint NOT NULL,
374374
place_id bigint NOT NULL,
375-
awarded bigint DEFAULT 0 NOT NULL
375+
awarded bigint DEFAULT 0 NOT NULL,
376+
CONSTRAINT asset_place_badge_unique UNIQUE (badge_id, place_id)
376377
);
377378

378-
379379
ALTER TABLE public.asset_place_badge OWNER TO postgres;
380380

381+
381382
--
382383
-- Name: asset_place_pass; Type: TABLE; Schema: public; Owner: postgres
383384
--

0 commit comments

Comments
 (0)