Hold /privacy behind a flag until counsel reads it, and fix leftover legal and email copy.
This commit is contained in:
1 parent
ead6c8f716
commit
072e5362f5
43 files changed
+548
-191
No files matched your search
@@ -55,4 +55,24 @@ describe("buildPublicSitemap", () => {
|
||||
lastModified: updatedAt,
|
||||
});
|
||||
});
|
||||
|
||||
it("omits /privacy while the policy flag is off", () => {
|
||||
const previous = process.env.ENABLE_PRIVACY_POLICY;
|
||||
const previousPublic = process.env.NEXT_PUBLIC_ENABLE_PRIVACY_POLICY;
|
||||
delete process.env.ENABLE_PRIVACY_POLICY;
|
||||
delete process.env.NEXT_PUBLIC_ENABLE_PRIVACY_POLICY;
|
||||
try {
|
||||
const urls = buildPublicSitemap().map((entry) => entry.url);
|
||||
expect(urls).not.toContain(sitemapUrl("/privacy"));
|
||||
expect(urls).toContain(sitemapUrl("/terms"));
|
||||
} finally {
|
||||
if (previous === undefined) delete process.env.ENABLE_PRIVACY_POLICY;
|
||||
else process.env.ENABLE_PRIVACY_POLICY = previous;
|
||||
if (previousPublic === undefined) {
|
||||
delete process.env.NEXT_PUBLIC_ENABLE_PRIVACY_POLICY;
|
||||
} else {
|
||||
process.env.NEXT_PUBLIC_ENABLE_PRIVACY_POLICY = previousPublic;
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user