remove tailing dots on toast messages

This commit is contained in:
seriousm4x
2023-08-19 00:23:07 +02:00
parent 84deb379e7
commit d7b4ef75de
4 changed files with 10 additions and 10 deletions

View File

@@ -33,7 +33,7 @@
$pocketbase.collection('permissions').subscribe('*', (event) => {
permission.set(event.record as Permission);
toast.success('Your permissions have been updated.');
toast.success('Your permissions have been updated');
});
}
});

View File

@@ -27,7 +27,7 @@
$pocketbase.admins
.update($pocketbase.authStore.model.id, { avatar: newAvatar })
.then(() => {
toast.success('Avatar saved.');
toast.success('Avatar saved');
})
.catch((err) => {
toast.error(err.message);
@@ -38,7 +38,7 @@
.collection('users')
.update($pocketbase.authStore.model.id, { avatar: newAvatar })
.then(() => {
toast.success('Avatar saved.');
toast.success('Avatar saved');
})
.catch((err) => {
toast.error(err.message);
@@ -70,7 +70,7 @@
if (j?.data?.password?.message) {
toast.error(j?.data?.password?.message);
} else if (j?.data?.passwordConfirm?.message) {
toast.error("Passwords don't match.");
toast.error("Passwords don't match");
} else if (j.data?.oldPassword?.message) {
toast.error(j.data.oldPassword.message);
} else {

View File

@@ -58,7 +58,7 @@
.collection('users')
.create(newUser)
.then((data) => {
toast.success(`User ${data.username} created.`);
toast.success(`User ${data.username} created`);
newUser.username = '';
newUser.password = '';
newUser.passwordConfirm = '';
@@ -74,14 +74,14 @@
.collection('users')
.delete(user.id)
.then(async () => {
toast.success(`User ${user.username} deleted.`);
toast.success(`User ${user.username} deleted`);
let permission = permissions.find((perm) => perm.user === user.id);
if (permission?.id !== undefined) {
await $pocketbase
.collection('permissions')
.delete(permission.id)
.then(() => {
toast.success(`Permissions for ${user.username} deleted.`);
toast.success(`Permissions for ${user.username} deleted`);
})
.catch((err) => {
toast.error(err.message);
@@ -130,7 +130,7 @@
// if (i > -1) {
// permissions[i] = data as Permission;
// }
toast.success(`Permissions for ${user.username} created.`);
toast.success(`Permissions for ${user.username} created`);
reload();
})
.catch((err) => {
@@ -142,7 +142,7 @@
.collection('permissions')
.update(permission.id, permission)
.then(() => {
toast.success(`Permissions for ${user.username} updated.`);
toast.success(`Permissions for ${user.username} updated`);
reload();
})
.catch((err) => {

View File

@@ -46,7 +46,7 @@
})
.catch((err) => {
if (err.data?.data?.passwordConfirm?.message) {
toast.error("Passwords don't match.");
toast.error("Passwords don't match");
} else if (err.data?.data?.email?.message) {
toast.error(err.data.data.email.message);
} else {