From a18075eea1adbec40ce2d071263cc6fba1b6301d Mon Sep 17 00:00:00 2001 From: Dillon Kearns Date: Fri, 24 Mar 2023 11:40:10 -0700 Subject: [PATCH] Fix condition for adding lamdera/codecs. --- generator/src/rewrite-elm-json.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/generator/src/rewrite-elm-json.js b/generator/src/rewrite-elm-json.js index ee194a9e..d1cbfbbb 100644 --- a/generator/src/rewrite-elm-json.js +++ b/generator/src/rewrite-elm-json.js @@ -31,7 +31,10 @@ function rewriteElmJsonHelp(elmJson, options) { elmJson["source-directories"] = elmJson["source-directories"].map((item) => { return "../../" + item; }); - if (options && options.executableName !== "elm") { + if (options && options.executableName === "elm") { + // elm, don't add lamdera/codecs + } else { + // lamdera, add codecs dependency elmJson["dependencies"]["direct"]["lamdera/codecs"] = "1.0.0"; } // 3. add our own secret My.elm module 😈