What is the difference between express-session 's req.session.regenerate method and direct assignment?

problem description

what"s the difference between creating session through the req.session.regenerate method and req.session.username = username?
I have used these two methods respectively, but I don"t find any difference. There are similar problems on stackoverflow, but I don"t quite understand. Who can tell me the address of
the original stackoverflow: https://stackoverflow.com/que.

.
Mar.11,2022
Menu