From d505653430b08686aadd77adfb5f62138f99275d Mon Sep 17 00:00:00 2001 From: Yorhel Date: Sat, 25 Aug 2018 16:40:44 +0200 Subject: TUWF::Validate::Interop: Update elm_type() for Elm 0.19 --- lib/TUWF/Validate/Interop.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/TUWF/Validate/Interop.pm b/lib/TUWF/Validate/Interop.pm index 946603c..de4444e 100644 --- a/lib/TUWF/Validate/Interop.pm +++ b/lib/TUWF/Validate/Interop.pm @@ -138,7 +138,7 @@ sub html5_validation { -# The elm_ are experimental, unstable, not very well-tested and for Elm 0.18 +# The elm_ are experimental, unstable, not very well-tested and for Elm 0.19 # Options: required any array values keys indent level sub elm_type { @@ -190,7 +190,7 @@ sub elm_encoder { return "$opt{json_encode}float" if $o->{type} eq 'num'; return "$opt{json_encode}int" if $o->{type} eq 'int'; return $opt{any} if $o->{type} eq 'any' && $opt{any}; - return sprintf '(%slist << List.map %s)', $opt{json_encode}, $opt{values} || $o->{values}->elm_encoder(%opt) + return sprintf '(%slist %s)', $opt{json_encode}, $opt{values} || $o->{values}->elm_encoder(%opt) if $o->{type} eq 'array' && ($opt{values} || $o->{values}); if($o->{type} eq 'hash' && ($o->{keys} || $opt{keys})) { -- cgit v1.2.3