Update intro/part6

This commit is contained in:
Richard Feldman
2018-08-14 02:20:10 -04:00
parent 3453035ffd
commit 3effe9e9d9

View File

@@ -30,7 +30,12 @@ decoder =
src : Avatar -> Attribute msg
src (Avatar maybeUrl) =
Html.Attributes.src (resolveAvatarUrl maybeUrl)
Html.Attributes.src <|
if maybeUrl == Just "" then
resolveAvatarUrl Nothing
else
resolveAvatarUrl maybeUrl
resolveAvatarUrl : Maybe String -> String