Skip to content

Commit

Permalink
devops: wait 2 minutes before running lhci (#107)
Browse files Browse the repository at this point in the history
* feat: load only 15 more

* fix: auth issues

* devops: wait 2 minutes before running lhci
  • Loading branch information
gaboesquivel authored Apr 8, 2024
1 parent 898ebce commit 05ac1af
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/lighthouse.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ jobs:
# header: lighthouse
# message: |
# Running Lighthouse audit...
- name: Wait for 2 minutes
run: sleep 120
- name: Capture Vercel preview URL
id: vercel_preview_url
uses: zentered/vercel-preview-url@v1.1.9
Expand Down
2 changes: 1 addition & 1 deletion apps/masterbots.ai/app/c/[chatbot]/[threadId]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export default async function ChatPage({ params }: ChatPageProps) {
} = await supabase.auth.getUser()
if (!user || !user.email) throw new Error('user not found')

const jwt = cookies().get('hasuraJwt').value || ''
const jwt = cookies().get('hasuraJwt')?.value || ''

console.log({ jwt, expired: isTokenExpired(jwt), user })
// NOTE: maybe we should use same expiration time
Expand Down
2 changes: 1 addition & 1 deletion apps/masterbots.ai/app/c/[chatbot]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export default async function BotThreadsPage({
})

if (!userProfile) throw new Error('user not found')
const jwt = cookies().get('hasuraJwt').value || ''
const jwt = cookies().get('hasuraJwt')?.value || ''

// NOTE: maybe we should use same expiration time
if (!jwt || isTokenExpired(jwt) || !user) redirect(`/auth/sign-in?next=/c`)
Expand Down
4 changes: 1 addition & 3 deletions apps/masterbots.ai/app/c/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,8 @@ interface ChatLayoutProps {
export default async function ChatLayout({ children }: ChatLayoutProps) {
return (
<main className="relative flex flex-col h-[calc(100vh_-_theme(spacing.16))] overflow-hidden">
{/* TODO: https://github.com/TheSGJ/nextjs-toploader/issues/66 */}
{/* <NextTopLoader color="#1ED761" initialPosition={0.20} /> */}
<ResponsiveSidebar />
<ChatLayoutSection>{children}</ChatLayoutSection>
{/* <ChatLayoutSection>{children}</ChatLayoutSection> */}
<div className="block lg:hidden">
<FooterCT />
</div>
Expand Down
2 changes: 1 addition & 1 deletion apps/masterbots.ai/components/shared/thread-list.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export default function ThreadList({
const moreThreads = await getBrowseThreads({
...filter,
offset: filteredThreads.length,
limit: 50
limit: 25
})

if (moreThreads.length === 0) setHasMore(false)
Expand Down

0 comments on commit 05ac1af

Please sign in to comment.