feat: allow to customize wakatime range (#874)

* chore: allow to customize wakatime data range

* docs: document wakatime range parameter
docs: add wakatime section to german readme

Co-authored-by: Anurag Hazra <hazru.anurag@gmail.com>
This commit is contained in:
Ferdinand Mütsch
2021-03-08 11:39:43 +05:30
committed by GitHub
co-authored by Anurag Hazra
parent 922f7165cb
commit 24e5f866c0
5 changed files with 36 additions and 5 deletions
+2 -1
View File
@@ -26,6 +26,7 @@ module.exports = async (req, res) => {
locale,
layout,
api_domain,
range,
border_radius,
} = req.query;
@@ -36,7 +37,7 @@ module.exports = async (req, res) => {
}
try {
const stats = await fetchWakatimeStats({ username, api_domain });
const stats = await fetchWakatimeStats({ username, api_domain, range });
let cacheSeconds = clampValue(
parseInt(cache_seconds || CONSTANTS.TWO_HOURS, 10),