mirror of
https://github.com/livebook-dev/livebook.git
synced 2025-09-04 20:14:57 +08:00
Escape more regex characters, closes #3041
This commit is contained in:
parent
5ce550fd5f
commit
acccc9e837
1 changed files with 1 additions and 1 deletions
|
@ -221,7 +221,7 @@ defmodule LivebookWeb.SessionHelpers do
|
|||
@spec sanitize_file_entry_name(String.t()) :: String.t() | nil
|
||||
def sanitize_file_entry_name(client_name) do
|
||||
client_name
|
||||
|> String.replace(~r/[^\s\w-.]/u, "")
|
||||
|> String.replace(~r/[^\s\w\-\.]/u, "")
|
||||
|> String.trim()
|
||||
|> String.replace(~r/\s+/u, "_")
|
||||
|> case do
|
||||
|
|
Loading…
Add table
Reference in a new issue