From 91e0b94e7ad1215e336db8a60443e19e1ed49f3a Mon Sep 17 00:00:00 2001 From: Michael Crumm Date: Mon, 23 Aug 2021 18:11:45 -0700 Subject: [PATCH] Extract archive with charlist cwd option h/t @michallepicki See https://github.com/phoenixframework/esbuild/pull/15 --- lib/dart_sass.ex | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/dart_sass.ex b/lib/dart_sass.ex index 2088d1f..d56083d 100644 --- a/lib/dart_sass.ex +++ b/lib/dart_sass.ex @@ -236,11 +236,11 @@ defmodule DartSass do end defp unpack_archive(".zip", zip, cwd) do - with {:ok, _} <- :zip.unzip(zip, cwd: cwd), do: :ok + with {:ok, _} <- :zip.unzip(zip, cwd: to_charlist(cwd)), do: :ok end defp unpack_archive(_, tar, cwd) do - :erl_tar.extract({:binary, tar}, [:compressed, cwd: cwd]) + :erl_tar.extract({:binary, tar}, [:compressed, cwd: to_charlist(cwd)]) end # Available targets: https://github.com/sass/dart-sass/releases