From 600880660a9454b4876da1ae816aab20044df371 Mon Sep 17 00:00:00 2001 From: Anton Zavodchikov Date: Sat, 2 Oct 2021 17:19:32 +0500 Subject: [PATCH] net.http: add a deprecated attribute for un/escape functions (#12037) --- vlib/net/http/http.v | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/vlib/net/http/http.v b/vlib/net/http/http.v index a830d578d0..2db9cccc74 100644 --- a/vlib/net/http/http.v +++ b/vlib/net/http/http.v @@ -197,22 +197,22 @@ fn build_url_from_fetch(config FetchConfig) ?string { return url.str() } -// unescape_url is deprecated, use urllib.query_unescape() instead +[deprecated: 'unescape_url is deprecated, use urllib.query_unescape() instead'] pub fn unescape_url(s string) string { panic('http.unescape_url() was replaced with urllib.query_unescape()') } -// escape_url is deprecated, use urllib.query_escape() instead +[deprecated: 'escape_url is deprecated, use urllib.query_escape() instead'] pub fn escape_url(s string) string { panic('http.escape_url() was replaced with urllib.query_escape()') } -// unescape is deprecated, use urllib.query_escape() instead +[deprecated: 'unescape is deprecated, use urllib.query_escape() instead'] pub fn unescape(s string) string { panic('http.unescape() was replaced with http.unescape_url()') } -// escape is deprecated, use urllib.query_unescape() instead +[deprecated: 'escape is deprecated, use urllib.query_unescape() instead'] pub fn escape(s string) string { panic('http.escape() was replaced with http.escape_url()') }