mirror of
https://github.com/zedeus/nitter
synced 2026-09-05 22:59:31 +00:00
Update todo list
This commit is contained in:
parent
dd8a7dcdff
commit
096471b50d
2 changed files with 11 additions and 9 deletions
|
|
@ -5,13 +5,13 @@ const key = "supersecretkey"
|
|||
|
||||
proc mimetype*(filename: string): string =
|
||||
if ".png" in filename:
|
||||
return "image/" & "png"
|
||||
"image/" & "png"
|
||||
elif ".jpg" in filename or ".jpeg" in filename:
|
||||
return "image/" & "jpg"
|
||||
"image/" & "jpg"
|
||||
elif ".mp4" in filename:
|
||||
return "video/" & "mp4"
|
||||
"video/" & "mp4"
|
||||
else:
|
||||
return "text/plain"
|
||||
"text/plain"
|
||||
|
||||
proc getHmac*(data: string): string =
|
||||
($hmac(sha256, key, data))[0 .. 12]
|
||||
|
|
|
|||
Loading…
Reference in a new issue