Skip to content

Commit

Permalink
Fixed exit logs
Browse files Browse the repository at this point in the history
  • Loading branch information
Tercioo committed Mar 11, 2022
1 parent 6795fd2 commit 1de5bfd
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
14 changes: 14 additions & 0 deletions classes/class_instance.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1775,6 +1775,20 @@ function _detalhes:ExportSkin()
}

elseif (self.StatusBarSaved) then
local leftName = self.StatusBarSaved.left
local centerName = self.StatusBarSaved.center
local rightName = self.StatusBarSaved.right

local options = self.StatusBarSaved.options

local leftOptions = createStatusbarOptions(options[leftName])
local centerOptions = createStatusbarOptions(options[centerName])
local rightOptions = createStatusbarOptions(options[rightName])

options[leftName] = leftOptions
options[centerName] = centerOptions
options[rightName] = rightOptions

exported.StatusBarSaved = DetailsFramework.table.copy({}, self.StatusBarSaved)
end
return exported
Expand Down
10 changes: 5 additions & 5 deletions core/parser.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5666,22 +5666,22 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
--> failed to load the framework.
return
end

_detalhes_global.exit_log = {}
_detalhes_global.exit_errors = _detalhes_global.exit_errors or {}

local saver_error = function (errortext)
_detalhes_global = _detalhes_global or {}
_detalhes_global.exit_errors = _detalhes_global.exit_errors or {}
tinsert (_detalhes_global.exit_errors, 1, currentStep .. "|" .. date() .. "|" .. _detalhes.userversion .. "|" .. errortext .. "|" .. debugstack())
tremove (_detalhes_global.exit_errors, 6)
end

_detalhes_global.exit_log = {}


_detalhes.saver_error_func = saver_error
_detalhes.logoff_saving_data = true

--> close info window
if (_detalhes.FechaJanelaInfo) then
tinsert (_detalhes_global.exit_log, "1 - Closing Breakdown Window.")
tinsert (_detalhes_global.exit_log, "1 - Closing Janela Info.")
currentStep = "Fecha Janela Info"
xpcall (_detalhes.FechaJanelaInfo, saver_error)
end
Expand Down

0 comments on commit 1de5bfd

Please sign in to comment.