updated interfaces and events

This commit is contained in:
erik-sn committed 2020-11-17 19:55:09 -05:00
1 parent b37e72d168
commit ead995eb69
9 files changed
+84 -10

No files matched your search

+7
View File
@@ -1,4 +1,5 @@
import { pool } from './db';
import { ESX } from "./server";
interface IPhoneNumber {
phone_number: string;
@@ -9,4 +10,10 @@ export async function usePhoneNumber(identifier: string): Promise<string> {
const [results] = await pool.query(query, [identifier]);
const phoneNumber = <IPhoneNumber[]>results;
return phoneNumber[0].phone_number;
}
export const getSource = () => parseInt(source);
export async function useIdentifier(): Promise<string> {
return ESX.GetPlayerFromId(getSource()).getIdentifier();
}
-1
View File
@@ -11,4 +11,3 @@ export let ESX: ESXServer = null;
emit("esx:getSharedObject", (obj: ESXServer) => (ESX = obj));
export const getSource = () => parseInt(source);
+2 -1
View File
@@ -1,5 +1,6 @@
import events from '../utils/events';
import { ESX, getSource } from './server';
import { ESX } from './server';
import { getSource } from "./functions";
import { pool } from './db';
import { resourceLimits } from 'worker_threads';
+2 -1
View File
@@ -1,6 +1,7 @@
import events from '../utils/events';
import { ESX, getSource } from './server';
import { ESX } from './server';
import { getSource } from "./functions";
import { pool } from './db';
import { usePhoneNumber } from './functions';
+2 -1
View File
@@ -1,5 +1,6 @@
import { pool } from "./db";
import { ESX, getSource } from "./server";
import { ESX } from "./server";
import { getSource } from "./functions";
import { Tweet, Profile } from '../../phone/src/common/interfaces/twitter';
import events from "../utils/events";
import config from "../utils/config";