Skip to content

Commit e960424

Browse files
RaisinTenbengl
authored andcommitted
src: convert hex2bin() into a regular function
No need to write hex2bin() as a function template because it's only called with a char parameter. Signed-off-by: Darshan Sen <[email protected]> PR-URL: #42321 Reviewed-By: Tobias Nießen <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
1 parent 78b858d commit e960424

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/node_url.cc

+1-2
Original file line numberDiff line numberDiff line change
@@ -222,8 +222,7 @@ void AppendOrEscape(std::string* str,
222222
*str += ch;
223223
}
224224

225-
template <typename T>
226-
unsigned hex2bin(const T ch) {
225+
unsigned hex2bin(const char ch) {
227226
if (ch >= '0' && ch <= '9')
228227
return ch - '0';
229228
if (ch >= 'A' && ch <= 'F')

0 commit comments

Comments
 (0)