mirror of https://github.com/sylv/micro.git
fix(web): paste expiration always being set
This commit is contained in:
parent
92cef85511
commit
af01384a1a
|
@ -120,7 +120,7 @@ export default function Paste() {
|
|||
title: values.title,
|
||||
};
|
||||
|
||||
if (values.expiryMinutes) {
|
||||
if (Number(values.expiryMinutes)) {
|
||||
const expiresInMs = Number(values.expiryMinutes) * 60 * 1000;
|
||||
body.expiresAt = Date.now() + expiresInMs;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue