diff --git a/src/Wave.elm b/src/Wave.elm index 6db6396..9219cc3 100644 --- a/src/Wave.elm +++ b/src/Wave.elm @@ -178,7 +178,7 @@ propagateInDirection : -> Direction -> ( Wave comparable, List { row : Int, column : Int } ) -> ( Wave comparable, List { row : Int, column : Int } ) -propagateInDirection source cell direction ( Wave wave, todo ) = +propagateInDirection source sourceCell direction ( Wave wave, todo ) = let target = Direction.move source direction @@ -195,7 +195,7 @@ propagateInDirection source cell direction ( Wave wave, todo ) = Just (Open remaining) -> let possibleInDirection = - case cell of + case sourceCell of Collapsed value -> Dict.get ( value, direction ) wave.rules |> Maybe.withDefault Set.empty