Skip to content

Commit

Permalink
fix(de): use en-US git history for de
Browse files Browse the repository at this point in the history
  • Loading branch information
caugner committed Oct 31, 2024
1 parent e71a443 commit 47ab291
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions content/document.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import {
} from "../libs/env/index.js";
import {
ACTIVE_LOCALES,
DEFAULT_LOCALE,
HTML_FILENAME,
MARKDOWN_FILENAME,
VALID_LOCALES,
Expand Down Expand Up @@ -302,8 +303,10 @@ export const read = memoize(

// The last-modified is always coming from the git logs. Independent of
// which root it is.
const gitHistory = getGitHistories(root, locale).get(
path.relative(root, filePath)
const gitHistoryRoot = locale === "de" ? CONTENT_ROOT : root;
const gitHistoryLocale = locale === "de" ? DEFAULT_LOCALE : locale;
const gitHistory = getGitHistories(gitHistoryRoot, gitHistoryLocale).get(
path.relative(gitHistoryRoot, filePath)
);
let modified = null;
let hash = null;
Expand Down

0 comments on commit 47ab291

Please sign in to comment.