Skip to content

Commit

Permalink
don't allow restoring when in combat
Browse files Browse the repository at this point in the history
  • Loading branch information
Krealle committed Sep 1, 2024
1 parent a83163c commit ab97d60
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Data/DBUtil.lua
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,11 @@ end
--- Restore layouts from a backup
---@param backupType "manual"|"automatic"
function DB.RestoreFromBackup(backupType)
if InCombatLockdown() then
CUF:Warn("Can't restore while in combat!")
return
end

---@type CUF.database.backup
local backup = CUF_DB.backups[backupType]
CUF:Log("|cff00ccffRestoreBackup:|r", backupType, backup.timestamp)
Expand Down

0 comments on commit ab97d60

Please sign in to comment.