updated core from 8.4 to 8.5 : bug with login_destination
This commit is contained in:
@@ -7,8 +7,8 @@ package: Core
|
||||
dependencies:
|
||||
- node
|
||||
|
||||
# Information added by Drupal.org packaging script on 2018-01-03
|
||||
version: '8.4.4'
|
||||
# Information added by Drupal.org packaging script on 2018-03-07
|
||||
version: '8.5.0'
|
||||
core: '8.x'
|
||||
project: 'drupal'
|
||||
datestamp: 1515021228
|
||||
datestamp: 1520457825
|
||||
|
||||
@@ -10,7 +10,8 @@
|
||||
|
||||
// Any comment that is older than 30 days is automatically considered read,
|
||||
// so for these we don't need to perform a request at all!
|
||||
const thirtyDaysAgo = Math.round(new Date().getTime() / 1000) - 30 * 24 * 60 * 60;
|
||||
const secondsIn30Days = 2592000;
|
||||
const thirtyDaysAgo = Math.round(new Date().getTime() / 1000) - secondsIn30Days;
|
||||
|
||||
// Use the data embedded in the page, if available.
|
||||
let embeddedLastReadTimestamps = false;
|
||||
@@ -44,11 +45,9 @@
|
||||
data: { 'node_ids[]': nodeIDs },
|
||||
dataType: 'json',
|
||||
success(results) {
|
||||
for (const nodeID in results) {
|
||||
if (results.hasOwnProperty(nodeID)) {
|
||||
storage.setItem(`Drupal.history.${currentUserID}.${nodeID}`, results[nodeID]);
|
||||
}
|
||||
}
|
||||
Object.keys(results || {}).forEach((nodeID) => {
|
||||
storage.setItem(`Drupal.history.${currentUserID}.${nodeID}`, results[nodeID]);
|
||||
});
|
||||
callback();
|
||||
},
|
||||
});
|
||||
|
||||
@@ -8,7 +8,8 @@
|
||||
(function ($, Drupal, drupalSettings, storage) {
|
||||
var currentUserID = parseInt(drupalSettings.user.uid, 10);
|
||||
|
||||
var thirtyDaysAgo = Math.round(new Date().getTime() / 1000) - 30 * 24 * 60 * 60;
|
||||
var secondsIn30Days = 2592000;
|
||||
var thirtyDaysAgo = Math.round(new Date().getTime() / 1000) - secondsIn30Days;
|
||||
|
||||
var embeddedLastReadTimestamps = false;
|
||||
if (drupalSettings.history && drupalSettings.history.lastReadTimestamps) {
|
||||
@@ -28,11 +29,9 @@
|
||||
data: { 'node_ids[]': nodeIDs },
|
||||
dataType: 'json',
|
||||
success: function success(results) {
|
||||
for (var nodeID in results) {
|
||||
if (results.hasOwnProperty(nodeID)) {
|
||||
storage.setItem('Drupal.history.' + currentUserID + '.' + nodeID, results[nodeID]);
|
||||
}
|
||||
}
|
||||
Object.keys(results || {}).forEach(function (nodeID) {
|
||||
storage.setItem('Drupal.history.' + currentUserID + '.' + nodeID, results[nodeID]);
|
||||
});
|
||||
callback();
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user