chat: When a user leaves, add time since they joined to the exit message.
authorRobert Hailey <github@osndok.com>
Wed, 2 Jan 2019 20:46:21 +0000 (14:46 -0600)
committerAndrey Petrov <shazow@gmail.com>
Wed, 2 Jan 2019 20:46:21 +0000 (15:46 -0500)
commit40bf20405848c7cd13764f3b987eba7d1bc05eb8
tree380f96729da73fb6c5ba589ae1927694430a2c4b
parent60f32028189001cd34aaab899f1124f3715f6a0c
chat: When a user leaves, add time since they joined to the exit message.

* Show the connection duration upon departure

* humantime: ugly sub-second precision replaces grammatically incorrect "1 seconds" message

* simplify function name

* humantime: repair unit test

* move: util/humantime -> internal/humantime

* go fmt everything
chat/message/user.go
chat/room.go
host.go
identity.go
internal/humantime/humantime.go [moved from humantime.go with 68% similarity]
internal/humantime/humantime_test.go [moved from humantime_test.go with 76% similarity]