Skip to content

Commit

Permalink
Merge pull request #196 from nikitaDanilenko/195-fix-option-only-elm-…
Browse files Browse the repository at this point in the history
…derivation

195 - Fix Option only Elm derivation
  • Loading branch information
pvillega authored Oct 14, 2023
2 parents 1af6da7 + 0cdfa33 commit 3967c27
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 0 additions & 2 deletions src/main/scala/bridges/elm/ElmFileBuilder.scala
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@ trait ElmFileBuilder {
}

val pipelineImport =
if (decoders.contains("required"))
"import Json.Decode.Pipeline exposing (..)"
else ""

val customImports = customTypeReplacements.values.filter(td => decoders.contains(td.newType)).flatMap(_.imports).mkString("\n")

Expand Down
2 changes: 1 addition & 1 deletion src/test/scala/bridges/elm/ElmFileBuilderSpec.scala
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ class ElmFileBuilderSpec extends AnyFreeSpec with Matchers {
module CustomModule2.ObjectsOnly exposing (..)

import Json.Decode as Decode

import Json.Decode.Pipeline exposing (..)
import Json.Encode as Encode


Expand Down

0 comments on commit 3967c27

Please sign in to comment.