 
     return mappedChannels
 
+  mapAccounts = (accounts)->
+    return [] unless accounts
+    mappedAccounts = []
+    accounts = [].concat(accounts)
+
+    for account in accounts
+      mappedAccounts.push {_id: account, constructorName : "JAccount"}
+    return mappedAccounts
+
   mapChannels = (channels)->
     return channels unless channels
     revivedChannels = []

      data = channel.channel
      data.isParticipant = channel.isParticipant
      data.participantCount = channel.participantCount
      data.participantsPreview = channel.participantsPreview
      c = new SocialChannel data
      # push channel into stack
      revivedChannels.push c

    plain._id = plain.id

    m = new KD.remote.api.SocialMessage plain
    m.account = mapAccounts(accountOldId)[0]

    m.replies      = mapActivities data.replies or []
    m.repliesCount = data.repliesCount
