From d5c983cddd32ab59133621f2303e0c7d3eedb87e Mon Sep 17 00:00:00 2001 From: Cooldude2606 Date: Tue, 3 Apr 2018 21:33:03 +0100 Subject: [PATCH] Edit To Error Function --- control.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/control.lua b/control.lua index 3c21e0c4..69a7e6a5 100644 --- a/control.lua +++ b/control.lua @@ -11,7 +11,7 @@ Discord: https://discord.gg/r6dC2uK -- replaces the base error function _error = error error = function(err) - if _G.Sync and game then + if _G.Sync and _G.Sync.emit_embeded and game then local color = _G.Color and Color.to_hex(defines.text_color.bg) or '0x0' Sync.emit_embeded{title='SCRIPT ERROR',color=color,description='There was an error in the script @Developers ',Error=err} elseif _G.error_handle and type(error_handle) == 'function' then