Make the messages_count_unread() general

Can we extend this function so that the unread messages of any user can be returned without duplicating this function again? Useful when using webservices.
Style cleanup
Merge pull request #1 from mrclay/pr-413

Style cleanup
Merge pull request #413 from teamwebgalli/patch-1

Allow specifying user in messages_count_unread()