Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork2k
Open
Description
Is this suited for github?
- Yes, this is suited for github
To Reproduce
- setup secondaryStorage
- create field under additionalFields for session
- it doesn't show up in session on login.
Current vs. Expected behavior
i checked session in redis. i use cookieCache so i also checked the cookie and decoded the jwt. field is missiing from both.
What version of Better Auth are you using?
1.4.0 beta
System info
{"system": {"platform":"darwin","arch":"arm64","version":"Darwin Kernel Version 24.6.0: Mon Jul 14 11:30:40 PDT 2025;","release":"24.6.0","cpuCount": 16,"cpuModel":"redacted","totalMemory":"128.00 GB","freeMemory":"20.62 GB" },"node": {"version":"v24.7.0","env":"development" },"packageManager": {"name":"npm","version":"11.5.1" },"frameworks": null,"databases": null,"betterAuth": {"version":"0.1.0","config": null }}Which area(s) are affected? (Select all that apply)
Backend
Auth config (if applicable)
import{betterAuth}from"better-auth"exportconstauth=betterAuth({secondaryStorage:{get:async(key)=>{constvalue=awaitredis.get(key)returnvalue ?value :null},set:async(key,value,ttl)=>{if(ttl){awaitredis.set(key,value,'EX',ttl)}elseawaitredis.set(key,value)},delete:async(key)=>{awaitredis.del(key)},},session:{additionalFields:{test:{type:'boolean',input:false,defaultValue:false,},},cookieCache:{enabled:true,maxAge:5*60,// 5 min},}});
Additional context
No response