Fix error when calling frame:MakeTop

This error was a result of changes made in commit 1642d10816
This commit is contained in:
Kenny Shields 2014-05-02 17:14:45 -04:00
parent 6c833ad975
commit a70de4136a

View File

@ -763,11 +763,12 @@ end
function newobject:MakeTop()
local key = 0
local base = loveframes.base
local basechildren = base.children
local numbasechildren = #basechildren
-- check to see if the object's parent is not the base object
if self.parent ~= loveframes.base then
if self.parent ~= base then
local baseparent = self:GetBaseParent()
if baseparent.type == "frame" then
baseparent:MakeTop()