unix timestamp extension

This commit is contained in:
Kwoth committed 2016-07-24 01:28:23 +02:00
1 parent cb5079a384
commit 21b1778a1f
1 file changed
+2
+2
View File
@@ -362,5 +362,7 @@ namespace NadekoBot.Extensions
return sw.BaseStream; return sw.BaseStream;
} }
public static double UnixTimestamp(this DateTime dt) => dt.ToUniversalTime().Subtract(new DateTime(1970, 1, 1)).TotalSeconds;
} }
} }