0
Fork 0
mirror of https://codeberg.org/SafeTwitch/safetwitch-backend.git synced 2024-12-21 20:53:00 -05:00

Use url encoding

This commit is contained in:
dragongoose 2023-08-25 19:42:43 -04:00
parent 17c6eb6a12
commit 283d5f21e0
No known key found for this signature in database
GPG key ID: 01397EEC371CDAA5

View file

@ -6,14 +6,14 @@ import (
)
func ProxyUrl(url string) string {
encodedUrl := b64.StdEncoding.EncodeToString([]byte(url))
encodedUrl := b64.URLEncoding.EncodeToString([]byte(url))
backendUrl := os.Getenv("URL")
return backendUrl + "/proxy/img/" + encodedUrl
}
func ProxyClip(url string) string {
encodedUrl := b64.StdEncoding.EncodeToString([]byte(url))
encodedUrl := b64.URLEncoding.EncodeToString([]byte(url))
backendUrl := os.Getenv("URL")
return backendUrl + "/proxy/clip/" + encodedUrl