fix: rename methods causing failures.

This commit is contained in:
ItzNotABug committed 2024-09-26 12:40:37 +05:30
1 parent ad96aae8ea
commit 12762271df
2 files changed
+4 -5

No files matched your search

@@ -6,7 +6,7 @@
import { HeaderAlert } from '$lib/layout';
import { isCloud } from '$lib/system';
import { upgradeURL } from '$lib/stores/billing';
import { hideNotificationBanner } from '$lib/helpers/notifications';
import { hideNotification } from '$lib/helpers/notifications';
import { backupsBannerId, showPolicyAlert } from '$lib/stores/database';
const isFreePlan = $organization?.billingPlan === BillingPlan.FREE;
@@ -19,7 +19,7 @@
function handleClose() {
showPolicyAlert.set(false);
hideNotificationBanner(backupsBannerId);
hideNotification(backupsBannerId);
}
</script>
+2 -3
View File
@@ -4,18 +4,17 @@ import { type Models, Query } from '@appwrite.io/console';
import { sdk } from '$lib/stores/sdk';
import { headerAlert } from '$lib/stores/headerAlert';
import BackupDatabase from '$lib/components/backupDatabaseAlert.svelte';
import { shouldShowNotificationBanner } from '$lib/helpers/notifications';
import { shouldShowNotification } from '$lib/helpers/notifications';
export const database = derived(page, ($page) => $page.data?.database as Models.Database);
export const backupsBannerId = 'databasesBackup';
export const showPolicyAlert = writable<boolean>(false);
export const userHidBackupsPromotion = writable<boolean>(false);
export async function checkForDatabaseBackupPolicies(database: Models.Database) {
// fast path: return if user dismissed the banner
if (!shouldShowNotificationBanner(backupsBannerId)) return;
if (!shouldShowNotification(backupsBannerId)) return;
let total = 0;