safe char regex exclusivity

This commit is contained in:
Elizabeth Hunt 2023-11-07 13:14:19 -07:00 committed by GitHub
parent 9e5682ca43
commit fcef09f104
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -96,7 +96,7 @@ defmodule Chessh.SSH.Client.TrongleChat do
height: height
} = state
) do
safe_char_regex = ~r/[ A-Za-z0-9._~()'!*:@,;+?-]/
safe_char_regex = ~r/^[ A-Za-z0-9._~()'!*:@,;+?-]+$/
appended_message_state =
case action do