Skip to content

Commit

Permalink
fixes a bug
Browse files Browse the repository at this point in the history
  • Loading branch information
rishabhpoddar committed Nov 24, 2023
1 parent b957b7b commit a291f5d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions recipe/session/recipe.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ func MakeRecipe(recipeId string, appInfo supertokens.NormalisedAppinfo, config *
if verifiedConfig.AntiCsrfFunctionOrString.FunctionValue != nil {
supertokens.LogDebugMessage("session init: AntiCsrf: function")
} else {
supertokens.LogDebugMessage("session init: AntiCsrf: " + *&verifiedConfig.AntiCsrfFunctionOrString.StrValue)
supertokens.LogDebugMessage("session init: AntiCsrf: " + verifiedConfig.AntiCsrfFunctionOrString.StrValue)
}
if verifiedConfig.CookieDomain != nil {
supertokens.LogDebugMessage("session init: CookieDomain: " + *verifiedConfig.CookieDomain)
Expand All @@ -68,7 +68,7 @@ func MakeRecipe(recipeId string, appInfo supertokens.NormalisedAppinfo, config *
}
// we intentionally use config here instead of verifiedConfig will always
// be a function for getting cookieSameSite.
if config.CookieSameSite == nil {
if config == nil || config.CookieSameSite == nil {
supertokens.LogDebugMessage("session init: CookieSameSite: default function")
} else {
supertokens.LogDebugMessage("session init: CookieSameSite: " + *config.CookieSameSite)
Expand Down

0 comments on commit a291f5d

Please sign in to comment.