This commit is contained in:
parent
fd4dbec9c9
commit
248cfede9e
@ -112,7 +112,7 @@ function include_news_api_latest_week {
|
||||
local query=$2
|
||||
local total=$3
|
||||
local since=$(date -d '- 7 days' +%Y-%m-%d)
|
||||
local news_of_the_week=$(curl -sk --retry 5 -H "X-Api-Key: ${NEWS_API_KEY}" -H 'User-Agent: Cazette/1.0' "https://api.newsdatahub.com/v1/news?language=fr&topic=technology&topic=business&topic=politics&topic=education&topic=innovation&topic=internet&&q=${query}&start_date=${since}" | jq '.data')
|
||||
local news_of_the_week=$(curl -sk --retry 5 -H "X-Api-Key: ${NEWS_API_KEY}" -H 'User-Agent: Cazette/1.0' "https://api.newsdatahub.com/v1/news?language=fr&topic=technology&topic=business&topic=politics&topic=education&topic=innovation&topic=internet&q=${query}&start_date=${since}" | jq '.data')
|
||||
|
||||
if [ -z "$news_of_the_week" ]; then
|
||||
return
|
||||
|
Loading…
Reference in New Issue
Block a user