Skip to content

Commit

Permalink
fix: apply code review
Browse files Browse the repository at this point in the history
  • Loading branch information
Sohee Lee committed Dec 5, 2018
1 parent e694675 commit af5a7ee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/js/request.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ var trackingIdMap = {
'image-editor': 'UA-129999381-1',
'component': 'UA-129987462-1'
};
var ms7days = 7 * 24 * 60 * 60 * 1000;

/**
* Check if the date has passed 7 days
Expand All @@ -26,7 +27,6 @@ var trackingIdMap = {
*/
function isExpired(date) {
var now = new Date().getTime();
var ms7days = 7 * 24 * 60 * 60 * 1000;

return now - date > ms7days;
}
Expand All @@ -47,7 +47,7 @@ function sendHostname(applicationId) {
var date = window.localStorage.getItem(applicationKeyForStorage);

// skip if the flag is defined and is set to false explicitly
if (!type.isUndefined(window.tui) && window.tui.usageStatistics === false) {
if (tui.usageStatistics === false) {
return;
}

Expand Down

0 comments on commit af5a7ee

Please sign in to comment.