mirror of
https://codeberg.org/SafeTwitch/safetwitch-backend.git
synced 2024-12-22 05:02:58 -05:00
Use url encoding
This commit is contained in:
parent
17c6eb6a12
commit
283d5f21e0
1 changed files with 2 additions and 2 deletions
|
@ -6,14 +6,14 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
func ProxyUrl(url string) string {
|
func ProxyUrl(url string) string {
|
||||||
encodedUrl := b64.StdEncoding.EncodeToString([]byte(url))
|
encodedUrl := b64.URLEncoding.EncodeToString([]byte(url))
|
||||||
backendUrl := os.Getenv("URL")
|
backendUrl := os.Getenv("URL")
|
||||||
|
|
||||||
return backendUrl + "/proxy/img/" + encodedUrl
|
return backendUrl + "/proxy/img/" + encodedUrl
|
||||||
}
|
}
|
||||||
|
|
||||||
func ProxyClip(url string) string {
|
func ProxyClip(url string) string {
|
||||||
encodedUrl := b64.StdEncoding.EncodeToString([]byte(url))
|
encodedUrl := b64.URLEncoding.EncodeToString([]byte(url))
|
||||||
backendUrl := os.Getenv("URL")
|
backendUrl := os.Getenv("URL")
|
||||||
|
|
||||||
return backendUrl + "/proxy/clip/" + encodedUrl
|
return backendUrl + "/proxy/clip/" + encodedUrl
|
||||||
|
|
Loading…
Reference in a new issue