mirror of
https://github.com/charlienet/go-mixed.git
synced 2026-03-04 12:10:13 +08:00
expr
This commit is contained in:
11
calendar/duration.go
Normal file
11
calendar/duration.go
Normal file
@@ -0,0 +1,11 @@
|
||||
package calendar
|
||||
|
||||
import "time"
|
||||
|
||||
func ParseDuration(s string) (time.Duration, error) {
|
||||
if len(s) == 0 {
|
||||
return time.Duration(0), nil
|
||||
}
|
||||
|
||||
return time.ParseDuration(s)
|
||||
}
|
||||
Reference in New Issue
Block a user