Skip to content

Commit

Permalink
Merge pull request #67 from blend-capital/pool-user-bug
Browse files Browse the repository at this point in the history
fix: take floor of timestamp for backstop pool user Q4W check
  • Loading branch information
mootz12 authored Aug 30, 2024
2 parents 5b5a117 + 9711b9c commit 007168a
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 11 deletions.
20 changes: 11 additions & 9 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@blend-capital/blend-sdk",
"version": "2.0.0",
"version": "2.0.1",
"description": "Javascript SDK for the Blend Protocol",
"type": "module",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion src/backstop/backstop_pool_user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export class BackstopPoolUser {
timestamp?: number | undefined
): Promise<BackstopPoolUser> {
if (timestamp === undefined) {
timestamp = Date.now() / 1000;
timestamp = Math.floor(Date.now() / 1000);
}
const rpc = new SorobanRpc.Server(network.rpc, network.opts);
const ledgerKeys: xdr.LedgerKey[] = [];
Expand Down

0 comments on commit 007168a

Please sign in to comment.