MCPcopy Create free account
hub / github.com/Effect-TS/effect / beginningOfSecond

Function beginningOfSecond

packages/effect/src/internal/schedule.ts:1674–1685  ·  view source on GitHub ↗
(now: number)

Source from the content-addressed store, hash-verified

1672
1673/** @internal */
1674export const beginningOfSecond = (now: number): number => {
1675 const date = new Date(now)
1676 return new Date(
1677 date.getFullYear(),
1678 date.getMonth(),
1679 date.getDate(),
1680 date.getHours(),
1681 date.getMinutes(),
1682 date.getSeconds(),
1683 0
1684 ).getTime()
1685}
1686
1687/** @internal */
1688export const endOfSecond = (now: number): number => {

Callers 3

cronFunction · 0.85
secondOfMinuteFunction · 0.85
endOfSecondFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected