decord/source/modules/messages/retrySendMessage.native.tsx

65 lines
2 KiB
TypeScript
Raw Normal View History

2026-07-28 08:39:19 +00:00
// Module ID: 9862
// Function ID: 76303
2026-07-20 16:05:17 +00:00
// Name: retrySendMessage
2026-07-28 08:39:19 +00:00
// Dependencies: [4158, 5695, 7994, 4699, 6169, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
2026-07-28 08:39:19 +00:00
// Module 9862 (retrySendMessage)
2026-07-23 10:11:24 +00:00
import { MessageSendLocation } from "MESSAGE_GROUP_SPACING";
let result = require("_createForOfIteratorHelperLoose").fileFinishedImporting("modules/messages/retrySendMessage.native.tsx");
2026-07-20 16:05:17 +00:00
export default function retrySendMessage(id, id2, arr) {
let content;
let flags;
let nonce;
let tts;
let obj = arg3;
2026-07-23 10:11:24 +00:00
const _require = id;
2026-07-20 16:05:17 +00:00
if (arg3 === undefined) {
obj = {};
}
2026-07-28 08:39:19 +00:00
importDefault(5695).deleteMessage(id.id, id2.id, true);
2026-07-20 16:05:17 +00:00
if (id2.isCommandType()) {
if (tmp17) {
2026-07-28 08:39:19 +00:00
_require(7994).retryCommandMessage(id2, id, obj);
const obj6 = _require(7994);
2026-07-20 16:05:17 +00:00
}
2026-07-23 10:11:24 +00:00
tmp17 = null != id2.interactionData && null != obj.applicationId;
2026-07-20 16:05:17 +00:00
} else {
const messageReference = id2.messageReference;
let mapped;
({ content, tts, flags, nonce } = id2);
if (null != arr) {
mapped = arr.map((on) => {
let fromJsonResult = on;
if (null == on.on) {
2026-07-23 10:11:24 +00:00
const CloudUpload = guildId(outer1_2[3]).CloudUpload;
2026-07-20 16:05:17 +00:00
fromJsonResult = CloudUpload.fromJson(on);
}
return fromJsonResult;
});
}
2026-07-28 08:39:19 +00:00
const obj3 = importDefault(5695);
2026-07-20 16:05:17 +00:00
id = id.id;
obj = { content, tts, invalidEmojis: [], validNonShortcutEmojis: [] };
obj = {};
const merged = Object.assign(obj);
obj["nonce"] = nonce;
obj["flags"] = flags;
let tmp9;
if (null != messageReference) {
tmp9 = messageReference;
}
obj["messageReference"] = tmp9;
obj["location"] = MessageSendLocation.RETRY;
obj["attachmentsToUpload"] = mapped;
obj["onAttachmentUploadError"] = function onAttachmentUploadError(file, code, reason) {
2026-07-23 10:11:24 +00:00
let obj = guildId(outer1_2[4]);
obj = { file, guildId: guildId.getGuildId(), analyticsLocations: [], code, reason };
2026-07-20 16:05:17 +00:00
const result = obj.handleUploadMessageAttachmentsErrors(obj);
};
obj3.sendMessage(id, obj, undefined, obj);
}
};