File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -57,14 +57,10 @@ export default async function ClientPreviewPage({
5757 return < InvalidToken />
5858 }
5959
60- console . log ( 'aaa raw token' , searchParams . token )
6160 const token = tokenParsed . data
62- console . log ( 'aaa token parsed' , token )
6361 const copilotClient = new CopilotAPI ( token )
64- console . log ( 'aaa copilotClient' , copilotClient )
6562 const tokenPayload = await copilotClient . getTokenPayload ( )
66- console . log ( 'aaa tokenPayload' , tokenPayload )
67- if ( ! tokenPayload || ! tokenPayload . clientId || ! tokenPayload . companyId ) {
63+ if ( ! tokenPayload ) {
6864 return < InvalidToken />
6965 }
7066
@@ -73,7 +69,7 @@ export default async function ClientPreviewPage({
7369 }
7470
7571 const clientId = z . string ( ) . uuid ( ) . safeParse ( tokenPayload . clientId )
76- if ( ! clientId . success ) {
72+ if ( ! clientId . success || ! tokenPayload . companyId ) {
7773 return < InvalidToken />
7874 }
7975
You can’t perform that action at this time.
0 commit comments