fixing bug where mostRecentChat was returning wrong type