summaryrefslogtreecommitdiff
path: root/lib/chessh/schema/node.ex
diff options
context:
space:
mode:
authorLogan Hunt <loganhunt@simponic.xyz>2022-12-30 05:53:15 -0700
committerGitHub <noreply@github.com>2022-12-30 05:53:15 -0700
commit52fbc0b0161d2d30583d7f04eef57a29e441e1d2 (patch)
treef882037a2820973ba6dc5f64206b01dba03266d8 /lib/chessh/schema/node.ex
parentc143bb549c53f2737c41cdfce6cc2598c5489bdc (diff)
parente7d8c61487815bd90ec5834dad5e6f64dd951b53 (diff)
downloadchessh-52fbc0b0161d2d30583d7f04eef57a29e441e1d2.tar.gz
chessh-52fbc0b0161d2d30583d7f04eef57a29e441e1d2.zip
Merge pull request #2 from Simponic/erlang_ssh_server
Erlang ssh server #2
Diffstat (limited to 'lib/chessh/schema/node.ex')
-rw-r--r--lib/chessh/schema/node.ex4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/chessh/schema/node.ex b/lib/chessh/schema/node.ex
index 867a6e2..8834aef 100644
--- a/lib/chessh/schema/node.ex
+++ b/lib/chessh/schema/node.ex
@@ -5,7 +5,7 @@ defmodule Chessh.Node do
@primary_key {:id, :string, []}
schema "nodes" do
- field(:last_start, :utc_datetime)
+ field(:last_start, :utc_datetime_usec)
end
def changeset(node, attrs) do
@@ -18,7 +18,7 @@ defmodule Chessh.Node do
nil -> %Chessh.Node{id: node_id}
node -> node
end
- |> Chessh.Node.changeset(%{last_start: DateTime.utc_now()})
+ |> changeset(%{last_start: DateTime.utc_now()})
|> Repo.insert_or_update()
end
end