diff --git a/assets/clone.html b/assets/clone.html
index 5857ed9..a9c118a 100644
--- a/assets/clone.html
+++ b/assets/clone.html
@@ -451,12 +451,12 @@
diff --git a/assets/index.html b/assets/index.html
index 5ae2722..3d7ac55 100644
--- a/assets/index.html
+++ b/assets/index.html
@@ -450,12 +450,12 @@
diff --git a/pastebin.go b/pastebin.go
index 60752e1..224d08d 100644
--- a/pastebin.go
+++ b/pastebin.go
@@ -14,7 +14,6 @@ import (
"io/ioutil"
"log"
"net/http"
- "strconv"
"time"
// uniuri is used for easy random string generation
@@ -108,9 +107,9 @@ func Sha1(paste string) string {
// DurationFromExpiry takes the expiry in string format and returns the duration
// that the paste will exist for
func DurationFromExpiry(expiry string) time.Duration {
- i, err := strconv.ParseInt(expiry, 10, 64)
+ duration, err := time.ParseDuration(expiry)
Check(err)
- return time.Hour * time.Duration(i)
+ return duration
}
// Save function handles the saving of each paste.