Skip to content

Commit

Permalink
fix(auth): update token
Browse files Browse the repository at this point in the history
  • Loading branch information
wisley7l committed Mar 11, 2024
1 parent ce2dbef commit 0e47914
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion functions/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ console.log(`-- Sheduled update E-Com Plus tokens '${cron}'`)

// update token job bling
const updateBlingToken = require('./lib/bling-auth/renovate-token')
const cronUpdateBlingToken = '1 */2 * * *'
const cronUpdateBlingToken = '*/30 * * * *'
exports.syncBlingToken = functions.pubsub.schedule(cronUpdateBlingToken).onRun(updateBlingToken)
console.log(`-- Sheduled active access from bling '${cronUpdateBlingToken}'`)

Expand Down
2 changes: 1 addition & 1 deletion functions/lib/bling-auth/create-access.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ module.exports = function (clientId, clientSecret, code, storeId, tokenExpiratio
clientId,
clientSecret,
updatedAt: now,
expiredAt: Timestamp.fromMillis(now.toMillis() + (2 * 60 * 60 * 1000))
expiredAt: Timestamp.fromMillis(now.toMillis() + (30 * 60 * 1000))
}

if (code) {
Expand Down

0 comments on commit 0e47914

Please sign in to comment.