Skip to content

Commit

Permalink
force liquidation info
Browse files Browse the repository at this point in the history
  • Loading branch information
ewansheldon committed Jun 25, 2024
1 parent 9fbacf8 commit 1f2bfb8
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/liquidation.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,12 @@ const getVaultManager = async _ => {
};

const scheduleLiquidation = async _ => {
const network = getNetwork('arbitrum');

// checks for undercollateralised vaults and liquidates
schedule.scheduleJob('6,36 * * * *', async _ => {
schedule.scheduleJob('6,36 * * * *', async _ => {
console.log('running liquidations')
const start = Math.floor(new Date / 1000);
const network = getNetwork('arbitrum');
const index = await getContract(network.name, 'SmartVaultIndex');
const { manager, wallet } = await getVaultManager();
const supply = Number((await getVaultSupply(wallet, manager)).toString());
Expand All @@ -87,7 +88,7 @@ const scheduleLiquidation = async _ => {
console.log(process.env.WEBHOOK_TOKEN);

// posts liquidation info to discord
schedule.scheduleJob('50 * * * *', async _ => {
schedule.scheduleJob('1 * * * *', async _ => {
console.log('logging liquidation info');
const { manager, wallet, provider } = await getVaultManager();
const EUROs = await getContract(network.name, 'EUROs');
Expand Down

0 comments on commit 1f2bfb8

Please sign in to comment.