Fixes for device and display first room event

Added util function to check if device is android
Fixed display first event of room
Sorted events on rooms/:id
Inline documentation