resolve-account
Advanced tools
Comparing version 1.0.16 to 1.0.17
@@ -20,3 +20,3 @@ (function (root, factory) { | ||
var SOURCE = 'library'; | ||
var VERSION = '1.0.16'; | ||
var VERSION = '1.0.17'; | ||
@@ -37,2 +37,3 @@ function ResolveAccount(options) { | ||
// @@@GO | ||
ResolveAccount.prototype.resolve = function (firebaseUser, account, options) { | ||
@@ -266,2 +267,3 @@ var self = this; | ||
var referralURL = new URL(window.location.origin || window.location.host); | ||
var accountCreationDate = new Date(+self.utilities.get(firebaseUser, 'metadata.createdAt', '0')); | ||
@@ -282,5 +284,5 @@ function _setAuthItem(selector, value) { | ||
authCreatedEl.setInnerHTML( | ||
new Date(+self.utilities.get(firebaseUser, 'metadata.createdAt', '0')) | ||
new Date(accountCreationDate) | ||
.toLocaleString(undefined, { | ||
weekday: 'long', year: 'numeric', month: 'long', day: 'numeric', | ||
year: 'numeric', month: 'long', day: 'numeric', | ||
}) | ||
@@ -327,5 +329,5 @@ ) | ||
var visibleStartDate = account.plan.trial.activated ? account.plan.trial.expires.timestamp : account.plan.payment.startDate.timestamp; | ||
// If basic, just show account creation date | ||
if (isBasicPlan) { | ||
// Set as start of this month | ||
visibleStartDate = new Date(now.getFullYear(), now.getMonth(), 1).toISOString(); | ||
visibleStartDate = accountCreationDate; | ||
} | ||
@@ -347,3 +349,3 @@ var visibleFrequency = account.plan.payment.frequency === 'unknown' ? 'monthly' : account.plan.payment.frequency; | ||
billingStartDateEl.setInnerHTML(new Date(visibleStartDate).toLocaleString(undefined, { | ||
weekday: 'long', year: 'numeric', month: 'long', day: 'numeric', | ||
year: 'numeric', month: 'long', day: 'numeric', | ||
})); | ||
@@ -350,0 +352,0 @@ billingExpirationDateEl.setInnerHTML(isBasicPlan && daysTillExpire < 366 |
{ | ||
"name": "resolve-account", | ||
"version": "1.0.16", | ||
"version": "1.0.17", | ||
"description": "Standardize account JSON structure for projects built under ITW Creative Works", | ||
@@ -5,0 +5,0 @@ "main": "./dist/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
25814
344