From 2f9c483d6d768610fda517a00bbaa851fc47c930 Mon Sep 17 00:00:00 2001 From: Dan Date: Fri, 12 Mar 2021 11:04:27 +0000 Subject: [PATCH] feat: only restore from backups if there are any --- cl_sync.lua | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/cl_sync.lua b/cl_sync.lua index 28ee1b6..8691211 100644 --- a/cl_sync.lua +++ b/cl_sync.lua @@ -92,8 +92,11 @@ function SYNC:SyncDataOnEnter() TriggerServerEvent( "wk_wars2x_sync:requestRadarData", driver ) elseif ( PLY:IsDriver() ) then UTIL:Notify( "Restoring local radar data" ) - -- Restore the local data - RADAR:RestoreFromBackup() + + if ( RADAR:IsThereBackupData() ) then + -- Restore the local data + RADAR:RestoreFromBackup() + end end end end