66 "github.com/supertokens/supertokens-golang/supertokens"
77)
88
9- func PrimitiveArrayClaim (key string , fetchValue FetchValueFunc , defaultMaxAgeInSeconds * int64 ) (* TypeSessionClaim , * PrimitiveArrayClaimValidators ) {
9+ func PrimitiveArrayClaim (key string , fetchValue FetchValueFunc , defaultMaxAgeInSeconds * int64 ) (TypeSessionClaim , PrimitiveArrayClaimValidators ) {
1010 if defaultMaxAgeInSeconds == nil {
1111 val := int64 (300 )
1212 defaultMaxAgeInSeconds = & val
@@ -47,7 +47,7 @@ func PrimitiveArrayClaim(key string, fetchValue FetchValueFunc, defaultMaxAgeInS
4747 return nil
4848 }
4949
50- validators := & PrimitiveArrayClaimValidators {
50+ validators := PrimitiveArrayClaimValidators {
5151 Includes : func (val interface {}, maxAgeInSeconds * int64 , id * string ) * SessionClaimValidator {
5252 if maxAgeInSeconds == nil {
5353 maxAgeInSeconds = defaultMaxAgeInSeconds
@@ -58,7 +58,7 @@ func PrimitiveArrayClaim(key string, fetchValue FetchValueFunc, defaultMaxAgeInS
5858 }
5959 return & SessionClaimValidator {
6060 ID : claimId ,
61- Claim : sessionClaim ,
61+ Claim : & sessionClaim ,
6262 ShouldRefetch : func (payload map [string ]interface {}, userContext supertokens.UserContext ) bool {
6363 claimVal , ok := sessionClaim .GetValueFromPayload (payload , userContext ).([]interface {})
6464 if ! ok || claimVal == nil {
@@ -119,7 +119,7 @@ func PrimitiveArrayClaim(key string, fetchValue FetchValueFunc, defaultMaxAgeInS
119119 }
120120 return & SessionClaimValidator {
121121 ID : claimId ,
122- Claim : sessionClaim ,
122+ Claim : & sessionClaim ,
123123 ShouldRefetch : func (payload map [string ]interface {}, userContext supertokens.UserContext ) bool {
124124 val , ok := sessionClaim .GetValueFromPayload (payload , userContext ).([]interface {})
125125 if ! ok || val == nil {
@@ -180,7 +180,7 @@ func PrimitiveArrayClaim(key string, fetchValue FetchValueFunc, defaultMaxAgeInS
180180 }
181181 return & SessionClaimValidator {
182182 ID : claimId ,
183- Claim : sessionClaim ,
183+ Claim : & sessionClaim ,
184184 ShouldRefetch : func (payload map [string ]interface {}, userContext supertokens.UserContext ) bool {
185185 val , ok := sessionClaim .GetValueFromPayload (payload , userContext ).([]interface {})
186186 if ! ok || val == nil {
@@ -242,7 +242,7 @@ func PrimitiveArrayClaim(key string, fetchValue FetchValueFunc, defaultMaxAgeInS
242242 }
243243 return & SessionClaimValidator {
244244 ID : claimId ,
245- Claim : sessionClaim ,
245+ Claim : & sessionClaim ,
246246 ShouldRefetch : func (payload map [string ]interface {}, userContext supertokens.UserContext ) bool {
247247 val , ok := sessionClaim .GetValueFromPayload (payload , userContext ).([]interface {})
248248 if ! ok || val == nil {
0 commit comments