mirror of
https://github.com/darksaid98/new-phone-who-dis.git
synced 2026-12-04 22:16:40 +00:00
fix(calls): fix some bugs encountered during refactor
This commit is contained in:
1 parent
10c5e97088
commit
af6e291368
9 files changed
+15
-15
No files matched your search
@@ -1,6 +1,7 @@
|
||||
import {
|
||||
CallEvents,
|
||||
CallWasAcceptedEvent,
|
||||
EndCallDTO,
|
||||
InitializeCallDTO,
|
||||
StartCallEventData,
|
||||
TransmitterNumDTO,
|
||||
@@ -57,7 +58,7 @@ onNetTyped<CallWasAcceptedEvent>(
|
||||
|
||||
// Rejected call
|
||||
RegisterNuiCB<TransmitterNumDTO>(CallEvents.REJECTED, (data, cb: NuiCallbackFunc) => {
|
||||
emitNet(CallEvents.REJECTED, data.transmitterNumber);
|
||||
emitNetTyped<TransmitterNumDTO>(CallEvents.REJECTED, data);
|
||||
cb({});
|
||||
});
|
||||
|
||||
@@ -66,7 +67,7 @@ onNet(CallEvents.WAS_REJECTED, async () => {
|
||||
animationService.endPhoneCall();
|
||||
});
|
||||
|
||||
RegisterNuiCB<TransmitterNumDTO>(CallEvents.END_CALL, async (data, cb) => {
|
||||
RegisterNuiCB<EndCallDTO>(CallEvents.END_CALL, async (data, cb) => {
|
||||
try {
|
||||
const serverRes: ServerPromiseResp<void> = await ClUtils.emitNetPromise(
|
||||
CallEvents.END_CALL,
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { IAlertProps } from '../../../typings/alerts';
|
||||
import { CallEvents, CallHistoryItem, CallRejectReasons } from '../../../typings/call';
|
||||
import { animationService } from '../animations/animation.controller';
|
||||
|
||||
const exp = (global as any).exports;
|
||||
|
||||
@@ -45,6 +46,7 @@ export class CallService {
|
||||
return emitNet(CallEvents.REJECTED, transmitter, CallRejectReasons.BUSY_LINE);
|
||||
|
||||
this.openCallModal(true);
|
||||
animationService.startPhoneCall();
|
||||
|
||||
SendNUIMessage({
|
||||
app: 'CALL',
|
||||
|
||||
Reference in new issue
Block a user