toying with Avatar caching
This commit is contained in:
parent
6e93762eee
commit
43d587b2ad
2 changed files with 3 additions and 1 deletions
|
@ -25,7 +25,8 @@ postNewAvatarR = do
|
|||
FormSuccess na -> do
|
||||
raw <- runResourceT $ fileSource (avatarNewFile na) $$ sinkLbs
|
||||
thumb <- generateThumb $ B.concat $ L.toChunks raw
|
||||
runDB $ insert_ $ Avatar (avatarNewIdent na) thumb
|
||||
now <- liftIO $ getCurrentTime
|
||||
runDB $ insert_ $ Avatar (avatarNewIdent na) thumb now
|
||||
setMessageI MsgAvatarUploadSuccessfull
|
||||
redirect $ HomeR
|
||||
_ -> do
|
||||
|
|
|
@ -32,6 +32,7 @@ CashCheck
|
|||
Avatar
|
||||
ident Text
|
||||
data ByteString
|
||||
altTime UTCTime default=now()
|
||||
deriving Typeable Show
|
||||
Barcode
|
||||
code Text
|
||||
|
|
Loading…
Reference in a new issue