mirror of
https://github.com/Vendicated/Vencord.git
synced 2025-02-24 15:35:11 +00:00
use findByPropsLazy
This commit is contained in:
parent
414d01a9da
commit
33aacf7277
1 changed files with 4 additions and 2 deletions
|
@ -8,7 +8,9 @@ import { UploadIcon } from "@components/Icons";
|
||||||
import { Devs } from "@utils/constants";
|
import { Devs } from "@utils/constants";
|
||||||
import definePlugin from "@utils/types";
|
import definePlugin from "@utils/types";
|
||||||
import { ChannelStore, MessageStore, PermissionsBits, PermissionStore, SelectedChannelStore, showToast, UserStore } from "@webpack/common";
|
import { ChannelStore, MessageStore, PermissionsBits, PermissionStore, SelectedChannelStore, showToast, UserStore } from "@webpack/common";
|
||||||
import { Common, findByProps } from "webpack";
|
import { Common, findByPropsLazy } from "webpack";
|
||||||
|
|
||||||
|
const uniqueIdProp = findByPropsLazy("uniqueId");
|
||||||
|
|
||||||
export default definePlugin({
|
export default definePlugin({
|
||||||
name: "AddAttachments",
|
name: "AddAttachments",
|
||||||
|
@ -57,7 +59,7 @@ export default definePlugin({
|
||||||
{
|
{
|
||||||
filename: file.name,
|
filename: file.name,
|
||||||
file_size: file.size,
|
file_size: file.size,
|
||||||
id: findByProps("uniqueId").uniqueId(),
|
id: uniqueIdProp.uniqueId(),
|
||||||
is_clip: false
|
is_clip: false
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
Loading…
Add table
Reference in a new issue