Add warning

This commit is contained in:
Thomas G 2022-10-31 19:50:26 +11:00
parent 6fb56171a9
commit d1f2dbc5aa
1 changed files with 8 additions and 0 deletions

View File

@ -19,8 +19,16 @@ function addWarning() {
document.body.appendChild(alertDiv);
}
function addDatabaseBackupRestoreWarning() {
let alertDiv = document.createElement("div");
alertDiv.innerHTML = "Please do not change any settings, accept/decline friend requests, send/delete messages or post to your feed. We are currently in the process of backing up our database.";
alertDiv.setAttribute("id","alert");
document.body.appendChild(alertDiv);
}
if (window.document.location.hostname == "archblox.com") {
console.log("User is on " + window.document.location.hostname + ". Supported URL.");
addDatabaseBackupRestoreWarning();
} else {
console.log("User is on " + window.document.location.hostname + ". Unsupported/legacy URL.");
addWarning();