From 142705f386f27767334421415c5da5787fe393e6 Mon Sep 17 00:00:00 2001 From: boatbomber Date: Wed, 10 Aug 2022 12:57:24 -0700 Subject: [PATCH] Fix security permission error (#619) --- plugin/src/Reconciler/diff.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugin/src/Reconciler/diff.lua b/plugin/src/Reconciler/diff.lua index 97819e32..ef729700 100644 --- a/plugin/src/Reconciler/diff.lua +++ b/plugin/src/Reconciler/diff.lua @@ -115,9 +115,13 @@ local function diff(instanceMap, virtualInstances, rootId) local childId = instanceMap.fromInstances[childInstance] if childId == nil then - if childInstance.Archivable == false then + -- pcall to avoid security permission errors + local success, skip = pcall(function() -- We don't remove instances that aren't going to be saved anyway, -- such as the Rojo session lock value. + return childInstance.Archivable == false + end) + if success and skip then continue end