aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs
diff options
context:
space:
mode:
Diffstat (limited to 'Zotlabs')
-rw-r--r--Zotlabs/Module/Sse_bs.php15
-rw-r--r--Zotlabs/Web/WebServer.php2
-rw-r--r--Zotlabs/Widget/Messages.php4
3 files changed, 13 insertions, 8 deletions
diff --git a/Zotlabs/Module/Sse_bs.php b/Zotlabs/Module/Sse_bs.php
index ca86f4f1f..388a9ba4d 100644
--- a/Zotlabs/Module/Sse_bs.php
+++ b/Zotlabs/Module/Sse_bs.php
@@ -55,8 +55,13 @@ class Sse_bs extends Controller {
self::$xchans = ids_to_querystr($x, 'xchan_hash', true);
}
- if(intval(argv(2)) > 0)
+ if(intval(argv(2)) > 0) {
self::$offset = argv(2);
+ }
+ else {
+ $_SESSION['sse_loadtime'] = datetime_convert();
+ }
+
$network = false;
$dm = false;
@@ -176,7 +181,7 @@ class Sse_bs extends Controller {
$sql_extra2
ORDER BY created DESC LIMIT $limit OFFSET $offset",
intval(self::$uid),
- dbescdate($_SESSION['page_loadtime']),
+ dbescdate($_SESSION['sse_loadtime']),
dbesc(self::$ob_hash)
);
@@ -252,7 +257,7 @@ class Sse_bs extends Controller {
$sql_extra2
ORDER BY created DESC LIMIT $limit OFFSET $offset",
intval(self::$uid),
- dbescdate($_SESSION['page_loadtime']),
+ dbescdate($_SESSION['sse_loadtime']),
dbesc(self::$ob_hash)
);
@@ -328,7 +333,7 @@ class Sse_bs extends Controller {
$sql_extra2
ORDER BY created DESC LIMIT $limit OFFSET $offset",
intval(self::$uid),
- dbescdate($_SESSION['page_loadtime']),
+ dbescdate($_SESSION['sse_loadtime']),
dbesc(self::$ob_hash)
);
@@ -415,7 +420,7 @@ class Sse_bs extends Controller {
$sql_extra2
ORDER BY created DESC LIMIT $limit OFFSET $offset",
intval($sys['channel_id']),
- dbescdate($_SESSION['page_loadtime']),
+ dbescdate($_SESSION['sse_loadtime']),
dbesc(self::$ob_hash),
dbescdate($_SESSION['static_loadtime'])
);
diff --git a/Zotlabs/Web/WebServer.php b/Zotlabs/Web/WebServer.php
index 685f75897..de0d5a883 100644
--- a/Zotlabs/Web/WebServer.php
+++ b/Zotlabs/Web/WebServer.php
@@ -39,8 +39,6 @@ class WebServer {
register_shutdown_function('session_write_close');
}
- $_SESSION['page_loadtime'] = datetime_convert();
-
/**
* Language was set earlier, but we can over-ride it in the session.
* We have to do it here because the session was just now opened.
diff --git a/Zotlabs/Widget/Messages.php b/Zotlabs/Widget/Messages.php
index 269d669dc..21375b08f 100644
--- a/Zotlabs/Widget/Messages.php
+++ b/Zotlabs/Widget/Messages.php
@@ -13,6 +13,8 @@ class Messages {
$page = self::get_messages_page($options);
+ $_SESSION['messages_loadtime'] = datetime_convert();
+
$tpl = get_markup_template('messages_widget.tpl');
$o = replace_macros($tpl, [
'$entries' => $page['entries'],
@@ -49,7 +51,7 @@ class Messages {
$offset = intval($options['offset']);
}
- $loadtime = (($offset) ? $_SESSION['page_loadtime'] : datetime_convert());
+ $loadtime = (($offset) ? $_SESSION['messages_loadtime'] : datetime_convert());
switch($options['type']) {
case 'direct':