Skip to content

Commit

Permalink
Remove draft filter in query
Browse files Browse the repository at this point in the history
  • Loading branch information
microbit-grace committed Dec 1, 2023
1 parent ef6e8b1 commit 6b7b0b4
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/documentation/ideas/content.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export const fetchIdeas = async (languageId: string): Promise<Idea[]> =>

const ideasQuery = (languageId: string): string => {
return `
*[_type == "pythonIdeasConfig" && language == "${languageId}" && !(_id in path("drafts.**"))][0]{
*[_type == "pythonIdeasConfig" && language == "${languageId}"][0]{
pythonIdeasOrder[]->{
_id, name, language, compatibility, image, slug,
content[] {
Expand Down
2 changes: 1 addition & 1 deletion src/documentation/mapping/content.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export const fetchMappingData = async (): Promise<ApiReferenceMap> =>

const mappingQuery = (): string => {
return `
*[_type == "pythonModule" && !(_id in path("drafts.**"))]{
*[_type == "pythonModule"]{
pythonModuleName,
pythonModuleItem[] {
pythonAlternativeContentLink,
Expand Down
2 changes: 1 addition & 1 deletion src/documentation/reference/content.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export const getTopicAndEntry = (
// This is necessary for the client-side search index.
const toolkitQuery = (languageId: string): string => {
return `
*[_type == "toolkit" && language == "${languageId}" && (slug.current == "explore" || slug.current == "reference") && !(_id in path("drafts.**"))]{
*[_type == "toolkit" && language == "${languageId}" && (slug.current == "explore" || slug.current == "reference")]{
id, name, description, language,
contents[]->{
name, slug, compatibility, subtitle, image,
Expand Down
2 changes: 1 addition & 1 deletion src/workbench/WelcomeDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ const WelcomeDialog = ({ isOpen, onClose }: WelcomeDialogProps) => {
};
const query = (): string => {
return `
*[_id == "pythonEditorConfig" && !(_id in path("drafts.**"))]{
*[_id == "pythonEditorConfig"]{
welcomeVideo
}`;
};
Expand Down

0 comments on commit 6b7b0b4

Please sign in to comment.