MCPcopy Create free account
hub / github.com/BingyanStudio/github-analyzer / updateSession

Method updateSession

api/src/services/sessionStore.ts:61–70  ·  view source on GitHub ↗

* Update an existing session with new data * @param sessionId The session ID * @param updatedData The updated session data

(
    sessionId: string,
    updatedData: Partial<UserSession>
  )

Source from the content-addressed store, hash-verified

59 * @param updatedData The updated session data
60 */
61 async updateSession(
62 sessionId: string,
63 updatedData: Partial<UserSession>
64 ): Promise<void> {
65 const session = await this.getSession(sessionId);
66 if (!session) return;
67
68 const updatedSession = { ...session, ...updatedData };
69 await this.saveSession(sessionId, updatedSession);
70 }
71
72 /**
73 * Refresh a token if it's close to expiration

Callers 1

refreshTokenIfNeededMethod · 0.95

Calls 2

getSessionMethod · 0.95
saveSessionMethod · 0.95

Tested by

no test coverage detected