Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

session additionalFields doesn't work when enabling secondaryStorage #5687

Open
Labels
bugSomething isn't working
@proof-llc

Description

@proof-llc

Is this suited for github?

  • Yes, this is suited for github

To Reproduce

  1. setup secondaryStorage
  2. create field under additionalFields for session
  3. 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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp