mirror of
https://github.com/roleypoly/roleypoly.git
synced 2025-04-24 19:39:11 +00:00
12 lines
335 B
TypeScript
12 lines
335 B
TypeScript
import { SessionData } from 'roleypoly/common/types';
|
|
import { respond, withSession } from '../utils/api-tools';
|
|
|
|
export const GetSession = withSession((session?: SessionData) => (): Response => {
|
|
const { user, guilds, sessionID } = session || {};
|
|
|
|
return respond({
|
|
user,
|
|
guilds,
|
|
sessionID,
|
|
});
|
|
});
|