mirror of
https://github.com/dutchcoders/transfer.sh.git
synced 2020-11-18 19:53:40 -08:00
Omit not needed end of slice
This commit is contained in:
parent
0605b8e271
commit
2f1de6fdb3
@ -111,7 +111,7 @@ func ProfileListener(s string) OptionFn {
|
|||||||
|
|
||||||
func WebPath(s string) OptionFn {
|
func WebPath(s string) OptionFn {
|
||||||
return func(srvr *Server) {
|
return func(srvr *Server) {
|
||||||
if s[len(s)-1:len(s)] != "/" {
|
if s[len(s)-1:] != "/" {
|
||||||
s = s + string(filepath.Separator)
|
s = s + string(filepath.Separator)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -121,7 +121,7 @@ func WebPath(s string) OptionFn {
|
|||||||
|
|
||||||
func TempPath(s string) OptionFn {
|
func TempPath(s string) OptionFn {
|
||||||
return func(srvr *Server) {
|
return func(srvr *Server) {
|
||||||
if s[len(s)-1:len(s)] != "/" {
|
if s[len(s)-1:] != "/" {
|
||||||
s = s + string(filepath.Separator)
|
s = s + string(filepath.Separator)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user