Skip to content

Commit d0548f3

Browse files
author
neurodynamic
committed
adds sorting of bugs by line number
1 parent f567e12 commit d0548f3

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

elm/Main/Update/BreakFile.elm

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,12 @@ run ({ filepath, fileContent } as config) =
2929
-- |> Result.mapError (Debug.log "error")
3030
|> Result.map (randomlySelectFileChangesFromParsedSegments config)
3131
|> Result.toMaybe
32+
|> Maybe.map
33+
(\{ newFileContent, changes } ->
34+
{ newFileContent = newFileContent
35+
, changes = List.sortBy .lineNumber changes
36+
}
37+
)
3238

3339

3440
type alias BreakResult =

0 commit comments

Comments
 (0)