mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-04 19:15:04 -04:00
WEB-29: Improve room page content loading
InitialSync: load the 30 last messages of each room so that a full page of messages can be displayed without additionnal request
This commit is contained in:
parent
f4094c5eb3
commit
45592ccdfd
3 changed files with 26 additions and 8 deletions
|
@ -104,8 +104,10 @@ angular.module('eventStreamService', [])
|
|||
settings.isActive = true;
|
||||
var deferred = $q.defer();
|
||||
|
||||
// Initial sync: get all information and the last message of all rooms of the user
|
||||
matrixService.initialSync(1, false).then(
|
||||
// Initial sync: get all information and the last 30 messages of all rooms of the user
|
||||
// 30 messages should be enough to display a full page of messages in a room
|
||||
// without requiring to make an additional request
|
||||
matrixService.initialSync(30, false).then(
|
||||
function(response) {
|
||||
var rooms = response.data.rooms;
|
||||
for (var i = 0; i < rooms.length; ++i) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue