mirror of
https://github.com/qbcore-fivem/qb-core.git
synced 2026-08-28 17:01:16 +00:00
Update utils.js
This commit is contained in:
+1
-1
@@ -13,7 +13,7 @@ export const isEnvBrowser = () => !window.invokeNative;
|
||||
export const fetchNui = async (evName, data, mockData = null) => {
|
||||
if (isEnvBrowser()) return mockData;
|
||||
|
||||
const resourceName = "qb-core";
|
||||
const resourceName = window.GetParentResourceName();
|
||||
|
||||
const rawResp = await fetch(`https://${resourceName}/${evName}`, {
|
||||
body: JSON.stringify(data),
|
||||
|
||||
Reference in New Issue
Block a user