Skip to content

Commit

Permalink
fix: value assigned to variable ESX is overwritten
Browse files Browse the repository at this point in the history
  • Loading branch information
bitpredator committed Nov 20, 2023
1 parent d5f1bc8 commit 234d191
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 8 deletions.
3 changes: 2 additions & 1 deletion .github/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,5 @@
33. [esx_dmvschool]: fix: fix lint error @bitpredator
34. [oxmysql]: chore: update to version 2.7.6 @bitpredator
35. [esx-radio] fix: fixed No such export addChannelCheck in resource pma-voice @bitpredator
36. [bpt_vehicletax]: chore: clean up the code @bitpredator
36. [bpt_vehicletax]: chore: clean up the code @bitpredator
37. [jsfour-idcard]: fix: value assigned to variable ESX is overwritten @bitpredator
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
fx_version 'adamant'

game 'gta5'

version '1.0.0'
ui_page 'html/index.html'

shared_script '@es_extended/imports.lua'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,4 @@
<script src="assets/js/materialize.js" type="text/javascript"></script>
<script src="assets/js/init.js" type="text/javascript"></script>
</body>
</html>
</html>
5 changes: 1 addition & 4 deletions server-data/resources/[esx_addons]/jsfour-idcard/server.lua
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
local ESX = nil
-- ESX
ESX = exports["es_extended"]:getSharedObject()

-- Open ID card
RegisterServerEvent('jsfour-idcard:open')
AddEventHandler('jsfour-idcard:open', function(ID, targetID, type)
ESX = exports["es_extended"]:getSharedObject()
local identifier = ESX.GetPlayerFromId(ID).identifier
local _source = ESX.GetPlayerFromId(targetID).source
local show = false
Expand Down

0 comments on commit 234d191

Please sign in to comment.