diff --git a/lib/api/controllers/users/userId/updateUserById.ts b/lib/api/controllers/users/userId/updateUserById.ts
index 1f10ba9..0868845 100644
--- a/lib/api/controllers/users/userId/updateUserById.ts
+++ b/lib/api/controllers/users/userId/updateUserById.ts
@@ -23,7 +23,8 @@ export default async function updateUserById(
id: userId,
},
});
- if (ssoUser) { // deny changes to SSO-defined properties
+ if (ssoUser) {
+ // deny changes to SSO-defined properties
if (data.email !== user?.email) {
return {
response: "SSO users cannot change their email.",
@@ -54,8 +55,8 @@ export default async function updateUserById(
status: 400,
};
}
-
- } else { // verify only for non-SSO users
+ } else {
+ // verify only for non-SSO users
// SSO users cannot change their email, password, name, username, or avatar
if (emailEnabled && !data.email)
return {
@@ -95,18 +96,18 @@ export default async function updateUserById(
id: { not: userId },
OR: emailEnabled
? [
- {
- username: data.username.toLowerCase(),
- },
- {
- email: data.email?.toLowerCase(),
- },
- ]
+ {
+ username: data.username.toLowerCase(),
+ },
+ {
+ email: data.email?.toLowerCase(),
+ },
+ ]
: [
- {
- username: data.username.toLowerCase(),
- },
- ],
+ {
+ username: data.username.toLowerCase(),
+ },
+ ],
},
});
@@ -135,7 +136,10 @@ export default async function updateUserById(
if (data.image?.startsWith("data:image/jpeg;base64")) {
if (data.image.length < 1572864) {
try {
- const base64Data = data.image.replace(/^data:image\/jpeg;base64,/, "");
+ const base64Data = data.image.replace(
+ /^data:image\/jpeg;base64,/,
+ ""
+ );
createFolder({ filePath: `uploads/avatar` });
@@ -163,9 +167,6 @@ export default async function updateUserById(
await prisma.user.findUnique({ where: { id: userId } })
)?.email;
-
-
-
// Other settings
const saltRounds = 10;
@@ -184,8 +185,6 @@ export default async function updateUserById(
archiveAsScreenshot: data.archiveAsScreenshot,
archiveAsPDF: data.archiveAsPDF,
archiveAsWaybackMachine: data.archiveAsWaybackMachine,
- displayLinkIcons: data.displayLinkIcons,
- blurredFavicons: data.blurredFavicons,
password:
data.newPassword && data.newPassword !== ""
? newHashedPassword
diff --git a/pages/login.tsx b/pages/login.tsx
index e1d12f6..2cccc7b 100644
--- a/pages/login.tsx
+++ b/pages/login.tsx
@@ -119,6 +119,10 @@ export default function Login({
className=" w-full text-center"
loading={submitLoader}
/>
+
+ {availableLogins.buttonAuths.length > 0 ? (
+
OR
+ ) : undefined}
>
);
}
@@ -127,14 +131,18 @@ export default function Login({
const Buttons: any = [];
availableLogins.buttonAuths.forEach((value, index) => {
Buttons.push(
- loginUserButton(value.method)}
- label={`Sign in with ${value.name}`}
- className=" w-full text-center"
- loading={submitLoader}
- />
+ <>
+ {index !== 0 ? OR
: undefined}
+
+ loginUserButton(value.method)}
+ label={`Sign in with ${value.name}`}
+ className=" w-full text-center"
+ loading={submitLoader}
+ />
+ >
);
});
return Buttons;
diff --git a/pages/settings/api.tsx b/pages/settings/api.tsx
index ea86de6..dc4bb9a 100644
--- a/pages/settings/api.tsx
+++ b/pages/settings/api.tsx
@@ -59,7 +59,7 @@ export default function Api() {
-
+
Status: Under Development
diff --git a/pages/subscribe.tsx b/pages/subscribe.tsx
index 3cb4aa2..3663f24 100644
--- a/pages/subscribe.tsx
+++ b/pages/subscribe.tsx
@@ -84,7 +84,7 @@ export default function Subscribe() {
Billed {plan === Plan.monthly ? "Monthly" : "Yearly"}