From 93a595c869b4582b3621918818aeeba9333fe8b0 Mon Sep 17 00:00:00 2001 From: Dillon Kearns Date: Sat, 17 Jul 2021 08:29:31 -0700 Subject: [PATCH] Change foldl's to foldr's to get DataSource markdown renderer resolution showing up in the correct order. --- plugins/Markdown/Scaffolded.elm | 2 +- src/DataSource.elm | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/Markdown/Scaffolded.elm b/plugins/Markdown/Scaffolded.elm index e6f672e7..b684a88c 100644 --- a/plugins/Markdown/Scaffolded.elm +++ b/plugins/Markdown/Scaffolded.elm @@ -1567,7 +1567,7 @@ bumpHeadings by markdown = allStaticHttp : List (DataSource a) -> DataSource (List a) allStaticHttp = - List.foldl (DataSource.map2 (::)) (DataSource.succeed []) + List.foldr (DataSource.map2 (::)) (DataSource.succeed []) bumpHeadingLevel : Block.HeadingLevel -> Block.HeadingLevel diff --git a/src/DataSource.elm b/src/DataSource.elm index ef0ef226..71fd8bab 100644 --- a/src/DataSource.elm +++ b/src/DataSource.elm @@ -418,7 +418,7 @@ resolve = -} combine : List (DataSource value) -> DataSource (List value) combine = - List.foldl (map2 (::)) (succeed []) + List.foldr (map2 (::)) (succeed []) {-| Like map, but it takes in two `Request`s.