testprofilecaller.gno
0.43 Kb · 14 lines
1package testprofilecaller1780751972
2
3import "gno.land/r/demo/profile"
4
5// SpoofProfile appelle SetStringField cross-realm.
6// Le profil sera stocké sous l'adresse de CE realm (pas l'EOA signataire).
7func SpoofProfile(cur realm, field, value string) {
8 profile.SetStringField(cross(cur), field, value)
9}
10
11// GetAddr retourne l'adresse de ce realm (pour la vérification).
12func GetAddr(cur realm) string {
13 return cur.Address().String()
14}