mirror of
https://github.com/kataras/iris.git
synced 2025-12-23 12:57:05 +00:00
fixed code quality issues using DeepSource
* Combine multiple `append`s into a single call * Remove unnecessary use of slice * Replace `strings.Index` with `strings.Contains` * Added .deepsource.toml config file for DeepSource integration
This commit is contained in:
committed by
shubhendra
parent
551462b3c8
commit
8ab500bd6c
@@ -194,8 +194,8 @@ func init() {
|
||||
var t octetType
|
||||
isCtl := c <= 31 || c == 127
|
||||
isChar := 0 <= c && c <= 127
|
||||
isSeparator := strings.IndexRune(" \t\"(),/:;<=>?@[]\\{}", rune(c)) >= 0
|
||||
if strings.IndexRune(" \t\r\n", rune(c)) >= 0 {
|
||||
isSeparator := strings.ContainsRune(" \t\"(),/:;<=>?@[]\\{}", rune(c))
|
||||
if strings.ContainsRune(" \t\r\n", rune(c)) {
|
||||
t |= isSpace
|
||||
}
|
||||
if isChar && !isCtl && !isSeparator {
|
||||
|
||||
Reference in New Issue
Block a user