Skip to content

Commit

Permalink
Simplify isPublicContentRepo expression
Browse files Browse the repository at this point in the history
Since `isHcp` and `isSentinel` aren't used elsewhere, this expression can be
simplified down to a one-liner

Co-authored-by:  Heat Hamilton <[email protected]>
  • Loading branch information
rmainwork and heatlikeheatwave committed Sep 6, 2024
1 parent 55e5a6d commit ee172e1
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/views/docs-view/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -418,9 +418,8 @@ export function getStaticGenerationFunctions<
* Note: If we need more granularity here, we could change this to be
* part of `rootDocsPath` configuration in `src/data/<product>.json`.
*/
const isHcp = product.slug == 'hcp'
const isSentinel = product.slug == 'sentinel'
const isPublicContentRepo = !isHcp && !isSentinel
const isPublicContentRepo =
product.slug !== 'hcp' && product.slug !== 'sentinel'
if (isPublicContentRepo) {
layoutProps.githubFileUrl = githubFileUrl
}
Expand Down

0 comments on commit ee172e1

Please sign in to comment.