Apply suggestion to lib/pleroma/web/activity_pub/object_validators/create_validator.ex
authorlain <lain@soykaf.club>
Tue, 24 Mar 2020 18:20:58 +0000 (18:20 +0000)
committerlain <lain@soykaf.club>
Tue, 24 Mar 2020 18:20:58 +0000 (18:20 +0000)
lib/pleroma/web/activity_pub/object_validators/create_validator.ex

index 9e480c4ed16f2194e0ba7d3c98b03b22565c2f01..872a12c48852dba24c9a96d8f86e4dc06c9a5918 100644 (file)
@@ -25,7 +25,6 @@ defmodule Pleroma.Web.ActivityPub.ObjectValidators.CreateNoteValidator do
   end
 
   def cast_data(data) do
-    %__MODULE__{}
-    |> cast(data, __schema__(:fields))
+    cast(%__MODULE__{}, data, __schema__(:fields))
   end
 end