bitwalker / timex_ecto

An adapter for using Timex DateTimes with Ecto
MIT License
162 stars 68 forks source link

Fix embeds for Timex.Ecto.Time #81

Closed archseer closed 5 years ago

archseer commented 6 years ago

** (FunctionClauseError) no function clause matching in Timex.Duration.to_clock/1

The following arguments were given to Timex.Duration.to_clock/1:

    # 1
    {0, -900, 0}

Attempted function clauses (showing 1 out of 1):

    def to_clock(%Timex.Duration{megaseconds: mega, seconds: sec, microseconds: micro})

(timex) lib/time/duration.ex:157: Timex.Duration.to_clock/1
(timex_ecto) lib/types/time.ex:32: Timex.Ecto.Time.cast/1