mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-11-27 13:47:58 +01:00
Phoenix implemented Param for float (phoenixframework/phoenix#4322)
This commit is contained in:
parent
5b6d941a36
commit
fe07a6b5ea
1 changed files with 0 additions and 11 deletions
|
@ -1,11 +0,0 @@
|
|||
defimpl Phoenix.Param, for: Float do
|
||||
# Another Phoenix sadness:
|
||||
#
|
||||
# "By default, Phoenix implements this protocol for integers, binaries,
|
||||
# atoms, and structs."
|
||||
#
|
||||
@spec to_param(float()) :: binary()
|
||||
def to_param(term) do
|
||||
Float.to_string(term)
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue