1
0
mirror of https://github.com/citizenfx/cfx-server-data.git synced 2026-05-13 17:03:10 +08:00

chat: only call RegisterKeyMapping when defined

This commit is contained in:
astatine
2020-04-13 07:45:30 +02:00
committed by blattersturm
Unverified
parent adfdb89895
commit abb38d4ff1
+3 -1
View File
@@ -228,7 +228,9 @@ local chatHideState = kvpEntry and tonumber(kvpEntry) or CHAT_HIDE_STATES.SHOW_W
local isFirstHide = true
if not isRDR then
RegisterKeyMapping('toggleChat', 'Toggle chat', 'keyboard', 'l')
if RegisterKeyMapping then
RegisterKeyMapping('toggleChat', 'Toggle chat', 'keyboard', 'l')
end
RegisterCommand('toggleChat', function()
if chatHideState == CHAT_HIDE_STATES.SHOW_WHEN_ACTIVE then