decord/source/modules/user_profile/utils/getCurrentUserProfile.tsx

25 lines
740 B
TypeScript
Raw Normal View History

// Module ID: 11119
// Function ID: 11120
2026-07-20 16:05:17 +00:00
// Name: getCurrentUserProfile
// Dependencies: [1371, 7635, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
// Module 11119 (getCurrentUserProfile)
import UserStore from "UserStore" /* 1371 */;
import UserProfileStore from "UserProfileStore" /* 7635 */;
2026-07-23 10:11:24 +00:00
const size = fn(2);
const result = size.fileFinishedImporting("modules/user_profile/utils/getCurrentUserProfile.tsx");
2026-07-20 16:05:17 +00:00
2026-07-29 08:29:29 +00:00
export default function getCurrentUserProfile(guildId) {
let id = UserStore.getCurrentUser();
2026-07-20 16:05:17 +00:00
if (null == id) {
return null;
2026-07-29 08:29:29 +00:00
} else if (null != guildId) {
2026-07-20 16:05:17 +00:00
id = id.id;
let guildMemberProfile = UserProfileStore.getGuildMemberProfile(id, guildId);
2026-07-20 16:05:17 +00:00
} else {
guildMemberProfile = UserProfileStore.getUserProfile(id.id);
2026-07-20 16:05:17 +00:00
}
};