projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Validate alias IDs
[akkoma]
/
lib
/
pleroma
/
config
/
config_db.ex
diff --git
a/lib/pleroma/config/config_db.ex
b/lib/pleroma/config/config_db.ex
index 2f4eb8581dba09e75552acea45388f230f7b9108..1a89d8895bda0c40db8117538ddae08d4a76995d 100644
(file)
--- a/
lib/pleroma/config/config_db.ex
+++ b/
lib/pleroma/config/config_db.ex
@@
-167,7
+167,9
@@
defmodule Pleroma.ConfigDB do
end)
end
end)
end
- @spec delete(map()) :: {:ok, ConfigDB.t()} | {:error, Changeset.t()}
+ @spec delete(ConfigDB.t() | map()) :: {:ok, ConfigDB.t()} | {:error, Changeset.t()}
+ def delete(%ConfigDB{} = config), do: Repo.delete(config)
+
def delete(params) do
search_opts = Map.delete(params, :subkeys)
def delete(params) do
search_opts = Map.delete(params, :subkeys)