An Ecto SQLite3 adapter.
0

Configure Feed

Select the types of activity you want to include in your feed.

Don't rescue on decode, just use non bang decode

Matthew Johnston (Jan 9, 2025, 9:04 AM -0600) bbe7ebe3 29519bb3

+4 -3
+4 -3
lib/ecto/adapters/sqlite3/codec.ex
··· 10 10 def bool_decode(v), do: {:ok, v} 11 11 12 12 def json_decode(v) when is_binary(v) do 13 - {:ok, Application.get_env(:ecto_sqlite3, :json_library, Jason).decode!(v)} 14 - rescue 15 - _ -> :error 13 + case Application.get_env(:ecto_sqlite3, :json_library, Jason).decode(v) do 14 + {:ok, decoded} -> {:ok, decoded} 15 + {:error, _reason} -> :error 16 + end 16 17 end 17 18 18 19 def json_decode(v), do: {:ok, v}