mirror of
https://github.com/1f349/go-webdav.git
synced 2024-12-22 08:14:15 +00:00
internal: fix Status text marshaling
This commit is contained in:
parent
69d8cf54ff
commit
3ea3818dd8
@ -33,7 +33,7 @@ func (s *Status) MarshalText() ([]byte, error) {
|
|||||||
if text == "" {
|
if text == "" {
|
||||||
text = http.StatusText(s.Code)
|
text = http.StatusText(s.Code)
|
||||||
}
|
}
|
||||||
return []byte(fmt.Sprintf("HTTP/1.1 %v %v", s.Code, s.Text)), nil
|
return []byte(fmt.Sprintf("HTTP/1.1 %v %v", s.Code, text)), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *Status) UnmarshalText(b []byte) error {
|
func (s *Status) UnmarshalText(b []byte) error {
|
||||||
|
Loading…
Reference in New Issue
Block a user