mirror of
https://github.com/logos-storage/logos-storage-contracts-eth.git
synced 2026-01-04 14:23:10 +00:00
vault: move Timestamp and TokensPerSecond libraries one level up
This commit is contained in:
parent
8df557801c
commit
284b54e575
@ -43,7 +43,7 @@ function _tokensPerSecondAtMost(
|
||||
return TokensPerSecond.unwrap(a) <= TokensPerSecond.unwrap(b);
|
||||
}
|
||||
|
||||
library TokenFlows {
|
||||
library Tokens {
|
||||
/// Calculates how many tokens are accumulated when a token flow is maintained
|
||||
/// for a duration of time.
|
||||
function accumulate(
|
||||
@ -1,8 +1,8 @@
|
||||
// SPDX-License-Identifier: MIT
|
||||
pragma solidity 0.8.28;
|
||||
|
||||
import "./TokenFlows.sol";
|
||||
import "./Timestamps.sol";
|
||||
import "../Tokens.sol";
|
||||
import "../Timestamps.sol";
|
||||
|
||||
/// Used to identify an account. The first 20 bytes consist of the address of
|
||||
/// the account holder, and the last 12 bytes consist of a discriminator value.
|
||||
@ -38,7 +38,7 @@ struct Flow {
|
||||
|
||||
library Accounts {
|
||||
using Accounts for Account;
|
||||
using TokenFlows for TokensPerSecond;
|
||||
using Tokens for TokensPerSecond;
|
||||
using Timestamps for Timestamp;
|
||||
|
||||
/// Creates an account id from the account holder address and a discriminator.
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
// SPDX-License-Identifier: MIT
|
||||
pragma solidity 0.8.28;
|
||||
|
||||
import "./Timestamps.sol";
|
||||
import "../Timestamps.sol";
|
||||
|
||||
struct Fund {
|
||||
/// The time-lock unlocks at this time
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user