projects
/
akkoma
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Fix twitter api date.
[akkoma]
/
lib
/
pleroma
/
object.ex
1
defmodule Pleroma.Object do
2
use Ecto.Schema
3
alias Pleroma.{Repo, Object}
4
import Ecto.Query
5
6
schema "objects" do
7
field :data, :map
8
9
timestamps()
10
end
11
12
def get_by_ap_id(ap_id) do
13
Repo.one(from object in Object,
14
where: fragment("? @> ?", object.data, ^%{id: ap_id}))
15
end
16
end