forked from rojo-rbx/rojo
Fix tooltips crashing on thread cancellation edge cases (#727)
This commit is contained in:
@@ -175,7 +175,7 @@ end
|
|||||||
|
|
||||||
function Trigger:willUnmount()
|
function Trigger:willUnmount()
|
||||||
if self.showDelayThread then
|
if self.showDelayThread then
|
||||||
task.cancel(self.showDelayThread)
|
pcall(task.cancel, self.showDelayThread)
|
||||||
end
|
end
|
||||||
if self.destroy then
|
if self.destroy then
|
||||||
self.destroy()
|
self.destroy()
|
||||||
@@ -225,7 +225,7 @@ function Trigger:managePopup()
|
|||||||
end)
|
end)
|
||||||
else
|
else
|
||||||
if self.showDelayThread then
|
if self.showDelayThread then
|
||||||
task.cancel(self.showDelayThread)
|
pcall(task.cancel, self.showDelayThread)
|
||||||
self.showDelayThread = nil
|
self.showDelayThread = nil
|
||||||
end
|
end
|
||||||
self.props.context.removeTip(self.id)
|
self.props.context.removeTip(self.id)
|
||||||
|
|||||||
Reference in New Issue
Block a user