Skip to content

Commit

Permalink
[desk-tool] Allow publish action on validation warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
rexxars committed Feb 19, 2020
1 parent e44e405 commit cd0e9c0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/@sanity/desk-tool/src/actions/PublishAction.tsx
Expand Up @@ -42,7 +42,7 @@ export function PublishAction(props) {
const validationStatus = useValidationStatus(id, type)
const syncState = useSyncState(id, type)

const hasValidationErrors = validationStatus.markers.length > 0
const hasValidationErrors = validationStatus.markers.some(marker => marker.level === 'error')

// we use this to "schedule" publish after pending tasks (e.g. validation and sync) has completed
const [publishScheduled, setPublishScheduled] = React.useState<boolean>(false)
Expand Down

1 comment on commit cd0e9c0

@vercel
Copy link

@vercel vercel bot commented on cd0e9c0 Feb 19, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.