Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/Classes/ImportTab.lua
Original file line number Diff line number Diff line change
Expand Up @@ -297,12 +297,12 @@ You can get this from your web browser's cookies while logged into the Path of E
if self.controls.importCodeMode.selIndex == 1 then
main:OpenConfirmPopup("Build Import", colorCodes.WARNING.."Warning:^7 Importing to the current build will erase ALL existing data for this build.", "Import", function()
self.build:Shutdown()
self.build:Init(self.build.dbFileName, self.build.buildName, self.importCodeXML, false, self.controls.importCodeIn.buf)
self.build:Init(self.build.dbFileName, self.build.buildName, self.importCodeXML, false, self.importCodeSite and self.controls.importCodeIn.buf or nil)
self.build.viewMode = "TREE"
end)
else
self.build:Shutdown()
self.build:Init(false, "Imported build", self.importCodeXML, false, self.controls.importCodeIn.buf)
self.build:Init(false, "Imported build", self.importCodeXML, false, self.importCodeSite and self.controls.importCodeIn.buf or nil)
self.build.viewMode = "TREE"
end
end
Expand Down Expand Up @@ -382,6 +382,8 @@ function ImportTabClass:Save(xml)
if self.build.importLink then
xml.attrib.importLink = self.build.importLink
end
-- Gets rid of erroneous, potentially infinitely nested full base64 XML stored as an import link
xml.attrib.importLink = (xml.attrib.importLink and xml.attrib.importLink:len() < 100) and xml.attrib.importLink or nil
end

function ImportTabClass:Draw(viewPort, inputEvents)
Expand Down