osanseviero HF staff josevalim commited on
Commit
64c40f1
1 Parent(s): e9d5ddf

Update run.exs (#1)

Browse files

- Update run.exs (bd7401281110a58ce760952b069b318dbea1b727)


Co-authored-by: José Valim <josevalim@users.noreply.huggingface.co>

Files changed (1) hide show
  1. run.exs +3 -1
run.exs CHANGED
@@ -1,6 +1,8 @@
1
  host =
2
  if repo_name = System.get_env("SPACE_REPO_NAME") do
3
- "#{System.get_env("SPACE_AUTHOR_NAME")}-#{String.replace(repo_name, "_", "-")}.hf.space"
 
 
4
  else
5
  "localhost"
6
  end
 
1
  host =
2
  if repo_name = System.get_env("SPACE_REPO_NAME") do
3
+ "#{System.get_env("SPACE_AUTHOR_NAME")}-#{repo_name}.hf.space"
4
+ |> String.replace("_", "-")
5
+ |> String.downcase(:ascii)
6
  else
7
  "localhost"
8
  end