Commit 3b2c2699fe21e5449950db42742e76760fa2a78c
1 parent
33fd58161a
Exists in
master
and in
1 other branch
minor changes, should update dependant apps
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
sql_sequrity.go
1 | package restutility | 1 | package restutility |
2 | 2 | ||
3 | import ( | 3 | import ( |
4 | "strings" | 4 | "strings" |
5 | ) | 5 | ) |
6 | 6 | ||
7 | func SQLProtect(in string) string { | 7 | func SQLSafeString(in string) string { |
8 | patern := "\"';&*<>=\\`:" | 8 | patern := "\"';&*<>=\\`:" |
9 | for _, c := range patern { | 9 | for _, c := range patern { |
10 | in = strings.Replace(in, string(c), "", -1) | 10 | in = strings.Replace(in, string(c), "", -1) |
11 | } | 11 | } |
12 | return in | 12 | return in |
13 | } | 13 | } |
14 | 14 |