Skip to content

Commit

Permalink
feat: hidden projects
Browse files Browse the repository at this point in the history
  • Loading branch information
GoldElysium authored May 26, 2024
1 parent c797fb0 commit ad7f083
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/app/[lang]/(StaticLayout)/projects/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ async function fetchProjects(lang: Language): Promise<Project[]> {

async function fetchNextProjects() {
// Fetch next page
const projectsRes = await fetch(`${process.env.NEXT_PUBLIC_CMS_URL!}/api/projects?limit=100&page=${page}&depth=2&locale=${lang}&fallback-locale=en`, {
const projectsRes = await fetch(`${process.env.NEXT_PUBLIC_CMS_URL!}/api/projects?limit=100&page=${page}&depth=2&locale=${lang}&fallback-locale=en&where[status][not_equals]=hidden`, {
headers: {
'X-RateLimit-Bypass': process.env.PAYLOAD_BYPASS_RATE_LIMIT_KEY ?? undefined,
Authorization: process.env.PAYLOAD_API_KEY ? `users API-Key ${process.env.PAYLOAD_API_KEY}` : undefined,
Expand Down
2 changes: 1 addition & 1 deletion src/app/sitemap.xml/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export async function GET() {

async function fetchNextProjects() {
// Fetch next page
const projectsRes = await fetch(`${process.env.NEXT_PUBLIC_CMS_URL!}/api/projects?depth=0&limit=100&page=${page}&depth=0`, {
const projectsRes = await fetch(`${process.env.NEXT_PUBLIC_CMS_URL!}/api/projects?depth=0&limit=100&page=${page}&where[status][not_equals]=hidden`, {
headers: {
'X-RateLimit-Bypass': process.env.PAYLOAD_BYPASS_RATE_LIMIT_KEY ?? undefined,
Authorization: process.env.PAYLOAD_API_KEY ? `users API-Key ${process.env.PAYLOAD_API_KEY}` : undefined,
Expand Down

0 comments on commit ad7f083

Please sign in to comment.