MCPcopy Create free account
hub / github.com/MathMan05/Fermi / constructor

Method constructor

src/webpage/user.ts:74–95  ·  view source on GitHub ↗
(userjson: userjson, owner: Localuser, dontclone: boolean = false)

Source from the content-addressed store, hash-verified

72 this.owner = owner;
73 if (getDeveloperSettings().logBannedFields && owner.user && owner.user.id !== userjson.id) {
74 this.checkfortmi(userjson);
75 }
76 if (!owner) {
77 console.error("missing localuser");
78 }
79 this.uid = userjson.id;
80 if (userjson.webhook_id) {
81 this.uid += ":::" + userjson.username;
82 console.log(this.uid);
83 }
84 userjson.uid = this.uid;
85 if (dontclone) {
86 this.userupdate(userjson);
87 this.hypotheticalpfp = false;
88 } else {
89 return User.checkuser(userjson, owner);
90 }
91 }
92 static makeSelector(
93 opt: Options,
94 doneText: string,
95 options: User[],
96 {single = false, addText = I18n.add()} = {},
97 ): Promise<Set<User> | void> {
98 return new Promise<Set<User> | void>((res) => {

Callers

nothing calls this directly

Calls 5

checkfortmiMethod · 0.95
userupdateMethod · 0.95
getDeveloperSettingsFunction · 0.90
errorMethod · 0.80
checkuserMethod · 0.80

Tested by

no test coverage detected